MyBB Community Forums

Full Version: [How To] Create Active State Button
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I'm wondering how to work in a menu system like MyBB's above. I have the menu, I've got the style and all that. (Provided by Template Inspired by 2.0).

I've changed the look to match as shown here:
This image shows what it looks like when a mouse is hovering over the button.
[Image: MenuIssue_hover.jpg]



But when I visit it, then remove the mouse from the button it reverts back to it's original state as shown here:
This image shows what it looks like when a mouse is moved and the page is visited.
[Image: MenuIssue_visited.jpg]



This is what I want to happen when the mouse is removed from the button and the page is visited.
[Image: MenuIssue_visited2.jpg]


Now that I've shown you what I am trying to figure out, I would like to add that I only want the page that is currently being viewed to be highlighted with white.


Additional information:
Website: http://d4250525.a404.response-hosting.com/rmt/index.php
Theme: INS Inspired by 2.0
CSS: http://d4250525.a404.response-hosting.co...global.css

I don't know what keywords to use to search for this tutorial, if there is one. If you have a link to a tutorial that shows how to do this, that would be great. If you know how to do this, that's awesome too.
@alan i think he means something different. Something that detects what page the user is currently on....and then uses a particular css for the corresponding menu item
I would also want that thing. Big Grin
Yes, that's exactly what the tutorial in the link does.

EDIT: I've just done a MyBB specific tutorial - http://community.mybb.com/thread-113632.html
Thank you, this has fixed my issue. Are there some general keywords we could add to this so other with similar issues can easily find it?