Adding current page to custom image menu buttons
-
Hey guys, I’m currently working on a site where I’ve got custom nav menu buttons set up with some html set up in the “navigation label”
Through this, I’ve been able to add in the button image with mouseover effects. I’m now trying to integrate a way to have the current page display the same image as mouseover.
This is what I have in the “navigation lable” section
<img src=”/example.png” onmouseover=”this.src=’/examplealt.png'” onmouseout=”this.src=’/example.png'”>
You can see the current function here:
I’d like to find a way to have it so that if im on the Blog page for example, the menu is displaying “examplealt.png” by default.
I have a feeling that the way that I have the buttons integrated currently will not work for what I’m going for.
I took a peek at the stylesheet that im using, but I cant seem to find the specific ID for each menu item, and its listed as “menu-item-ancestor” instead.
-
You did not specify a blog address or reason for posting when you created this topic.
This support forum is for blogs hosted at WordPress.com. If your question is about a self-hosted WordPress blog then you’ll find help at the WordPress.org forums.
If you don’t understand the difference between WordPress.com and WordPress.org, you may find this information helpful.
If you forgot to include a link to your blog, you can reply and include it below. It’ll help people to answer your question.
This is an automated message.
- The topic ‘Adding current page to custom image menu buttons’ is closed to new replies.