Page 1 of 1

Navigation button colur stays rolled over colour after click

Posted: Wed Oct 27, 2004 10:42 am
by hairyjim
Hi all,

Within a products section of my website I have several modules related to a product. What I want is to have a navigation bar that has the names of each module as links throughs to the relevant module pages.

What I would really like to be able to achieve is when a particular module button is clicked and the relevant page is loaded the colour of the clicked button is different to the rest on the navigation bar as an indicator to the module page they are viewing.

One way i thought of doing this ws to have a different navigation bar for each module section with the relevant button being a different colour, but this seems an awkward design.

Could someone point me in the direction to a more straight forward solution to this.

Posted: Wed Oct 27, 2004 10:55 am
by kettle_drum
Well you can set the colour of visted links with vlink="" in the body tag using html or with a.visited {} in css.

Posted: Wed Oct 27, 2004 11:02 am
by hairyjim
I only wish the button colour to be different if they are viewing that section.

Posted: Wed Oct 27, 2004 11:23 am
by kettle_drum
Just use some php to check the current page - to figure out what section its in - and then give the link the desired class to make it coloured.

Posted: Thu Oct 28, 2004 3:30 am
by hairyjim
I was kinda hoping not to pass page vars through the URL.

But it would work nicely I suppose.