Archived topic
Dropdown navigation
7 replies · Started by Pam Mandel on June 22, 2016
Hiya. I searched the forums, I promise. :)
I want my primary nav to do this:
FAQs
-- FAQ1
-- FAQ2
Where FAQs reveals the list and on click, FAQ1 goes to, you guessed it, FAQ1.
I guess I want a nested primary nav? I built a page to serve as a nav aid on for some other stuff, but now that I want a second dropdown menu in the navigation, welp...
As always, thanks, I get lots of compliments on the site design -- that's all you.
Can I do this? It doesn't seem I can create a navigation only item without entering a URL.
Thanks!
Hi there,
If I'm understanding, this should help: https://generatepress.com/knowledgebase/using-menus/#create-drop-down-menu-custom
Let me know :)
I'm having the same issue. I'm using an ordinary page (no custom link) for the top menu and have sub menu pages under that. Clicking on the main menu top level page simply displays the sub menu items without going to the main/top level page. The top level page thus basically goes away. :(
(I'm a newbie, but am loving GeneratePress.)
Sounds like you have the "Dropdown type" setting in "Customize > Layout" set to "Click - Menu Item".
That will use the entire menu item as the click.
You can switch it to "Click - Arrow" so only clicking on the arrow does the dropdown, and clicking on the menu takes you to the page.
Hope this helps :)
Hello Tom, Is there a way to use the hover option for desktop views and the click block/text option for mobile?
Thank you in advance for any help.
Tanya
Hi Titiana,
You can try this PHP snippet:
add_filter( 'option_generate_settings','click_tap_on_mobile' );
function click_tap_on_mobile( $options ) {
if ( wp_is_mobile() ) {
$options['nav_dropdown_type'] = 'click-arrow';
}
return $options;
}
But this isn't necessary as even if the menu dropdown is set to "hover", you'll still have to tap on mobile to open the dropdown as there's no mouse pointer that hovers when you visit the site on mobile devices. That, in a sense, automatically makes mobile device dropdowns "on tap to expand" by default.
Hello Elvin, Thank you so much - When I choose hover - the only part of the mobile menu that is clickable is the arrow. That is why I wanted to use the "click menu item" for mobile and the hover for desktops. If there is a way to make the "hover" option have the "click menu item" functionality on a mobile that would be great. Customers find it difficult to click small arrows on navigations.
I will try the snippet now :)
The functionality you've asked sounds like how it behaves by default when you set it to "hover"
Try leaving it to hover and don't add the PHP snippet added.
