- This topic is empty.
Viewing 7 posts - 1 through 7 (of 7 total)
Viewing 7 posts - 1 through 7 (of 7 total)
- The forum ‘CSS’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Okay I got things sorted with the navigation.. Thank you jamy_za! But, now since my images are sprites, what code would I be needing to use if I want the ‘current’ page part of the sprite used? And how can I make sure whenever I switch pages, the correct ‘current’ will be seen? I have the other two states working.
I used to wonder this all the time, but its pretty simple. Have the body tag have a different ID on each of your pages. For example
After that in your css use something that targets the body and the ul li a, so only when the css can target the current body ID, will that anchor be lit up.
#bodyID #navID ul li a {background-position:bottom;}
#bodyID2 #navID2 ul li a {background-position:bottom;}
I am building a theme on WordPress..
Wordpress makes it even easier!
I would use their built-in menu function which will automatically add the classes for you.
You’ll need to change your class names in your CSS file to match what WP outputs so that your sprites will still work.
you lost me? built-in function? Where?
omfg never mind .. I will strangle myself later.. I been watching very old tutorials for WP.. CHRIS!! Make an updated .PSD Webpage to WP tut/video!!!