Header dropdown menu does not work in a third-party theme

Hello,

I’ve a problem with the header account menu dropdown not functioning. It alway open. Using blocksy themes. When try using other themes, no such problem. Is anyone else facing the same problem. Anyone have solution?

If there is no solution, how do I remove the hivepress account from the header menu? I’ve try but it not removing the account menu.


function remove_menu_item($items, $menu, $args) {
    foreach ($items as $key => $item) {
        if ($item->title == 'admin5') { 
            unset($items[$key]);
        }
    }
    return $items;
}
add_filter('wp_get_nav_menu_items', 'remove_menu_item', 10, 3);

Thanks.

Did you try with a “native” Hivepress theme ?

Yes, ListingHive themes is working but limited customization feature. That why prefer to use other themes.

Hi,

If you are using a third-party theme, we are sorry to say that we cannot assist you as third-party themes may require custom integration. For more information, please see this documentation: Compatibility with third-party themes - HivePress Help Center

Found out this css class ‘animated-submenu-block’ is missing from hivepress account menu dropdown. How to add this css class into it?

Something like this (but on your new theme/child theme) :

What i means is to add custom class to hivepress header dropdown menu so it can close the dropdown. Currently the hivepress account dropdown unable to close.

I have try

add_filter(
	'hivepress/v1/menus/menu',
	function( $args ) {
		return hivepress()->helper->merge_arrays(
			$args,
			[
				'attributes' => [
					'class' => [ 'custom_class' ],
				],
			]
		);
	}
);

This only add to <ul> but I want to add custom class to <li> of hivepress account

Hi,

Please make sure that your theme supports drop-down menus by default, and also check errors in the JS console; maybe the drop-down script is broken because we render drop-downs with the same classes and HTML markup as WordPress, and it should work with any theme if it supports drop-down menus.
If you want to implement a CSS or JS drop-down, or just hide the drop-down, then the CSS drop-down menu will be like this: .sub-menu.hp-menu--user-account

​I hope this is helpful to you.