How to mke a non clickable menu tab

Guys, it may be a simple thing but just cannot work it out

I’m looking to find out how to implement a non-clickable tab
I’m looking to put at least 5 sub tabs in one of the menu tabs but do not want the main tab to be clickable

putting a sub-tab under the main tab is easy by drag and drop, but this still makes the main tab still clickable

all help on this would be grateful

What theme are you using?

mountain

Marathia used to make a NoLink stack but I can’t see it on his page now.

You used to put it on every page you want your visitor to see. Leave it off the top level page and it won’t be clickable. I’ve just tested it with Mountain and it works. Maybe drop him a line and see if he has a newer alternative I don’t know about? https://rapidweaver.marathia.com/stacks/

There may also be a clever way to do with it a bit of code, but I can’t help there.

HTH

Rob

1 Like

The exact code varies on a theme-by-theme basis.

However for the freebie Mountains theme included in RapidWeaver 8, you can use some simple CSS code like this:

.dropdown-toggle {
    pointer-events: none;	
}

That will have the effect of disabling links, that have sub pages.

Enter this CSS code in Settings > Code > CSS or Page Inspector > Code > CSS.

The CSS pointer-events property is well supported by all modern web browsers:
https://caniuse.com/#search=pointer-events

The benefit of this method over using a stack is that it’ll work with any RapidWeaver page type.

A word of warning - you definitely do want to setup the parent page as a redirect (use an offsite page type for this task) or continue to include some basic written content and links.

The reason for this is because search engines indexing your website dislike blank pages; especially those at a parent level.

It also means that should the website user still stumble upon your deactivated page via a good educated guess, breadcrumb links or the mobile menu, they still see something.

3 Likes

I would also uncheck the “Index this page” in the Meta Tags page of the right-hand inspector for the top-level page. That will tell search engines not to index it. While search engines don’t have to follow this instruction, all the good search engines do. It’s just a little extra protection to keep it out of the search results.

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