Can I make a dropdown nav in the top links not clickable?

Hi There!

This seems to be the opposite problem of what most people are asking about in this forum, but I’d like to know how I can get a desktop “top links” to behave the same way as it does on mobile.

I would like the user to not be able to click on “TEAM”. I only want them to be able to click on the dropdown links.

Is there any way to do this?

Thanks in advance!

– Katie

Hello Katie,

Thanks for writing in!

Regretfully there is no option to disable the top links in the header builder. You can only do it using a custom css. For example, you can add a code something like this in your header builder’s custom css section:

#menu-item-12345 a {
    pointer-events: none;
}

wherein 12345 is the menu ID. This code will not work out of the box since you must supply the menu ID first. To find out menu id, please take a look at following article. https://wpsites.net/tools/find-nav-menu-item-i-d/

Hope this helps.

Thank you for the quick reply! I found the menu ID and inserted it into my CSS code. It works, but there’s a hitch. I now can’t click on the dropdown items under it. In this situation, I wanted to be able for the user to not click on the top link only.

Is there a way to do this?

Thanks again!

Hi there,

An easy way to do this is to add the main menu item that you do not want to link as a Custom Link then set javascript:void(0); to the URL field of the custom link.

Hope this helps.

That worked like a charm. :slight_smile: Thanks Jade!

You are most welcome. :slight_smile:

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.