Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS getting the "current" class for an a tag

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #23484

    Silly question probably… I don’t know how this is done… Lets say for tabs, you select a tab, and it keeps the link the new color since it now has the class of "current".

    Chris uses this in his side scrolling coda-like side bar for the above images. Each time you click on a tab, the selected tab is now displayed. I looked into the CSS and I can understand its adding the current class to the link, I’m not just sure how that is happening.

    Thanks!

    #50793
    Argeaux
    Participant

    You can use php to read the urlbar and check if the page you are on is on is the same as the one in the menu. Its kinda hard to explain how to do it, but if you google for php get you get some examples.

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.