| Complete Noob - CSS Help Needed! Changing Hyperlinks Colors |
Strider30

msg:4543678 | 2:21 am on Feb 8, 2013 (gmt 0) | Hi all, I'm a complete noob when it comes to CSS. Hoping for some help here. I've got a box with a few hyperlinks that I want to change the color on. Here's the coding that I'm using: <div class="box"> <left>My Other Sites</left> <left> <a href="http://www.myotherwebsite.net">Basketball Quotes</a></left> <left> <a href="http://www.my next website.net">Football Quotes</a></left> </div> My question is this: How do I change those links to show as blue? Currently they're gray. Thanks in advance for your time.
|
Marshall

msg:4543680 | 2:36 am on Feb 8, 2013 (gmt 0) | .box a { color: #00f } It might, however, be better to assign an id to the <div> to limit the effect to the one <div>, e.g. #links a { color: #00f; } <div id="links" class="box"> <left>My Other Sites</left> <left> <a href="http://www.myotherwebsite.net">Basketball Quotes</a></left> <left> <a href="http://www.my next website.net">Football Quotes</a></left> </div> Marshall
|
Fotiman

msg:4543682 | 2:39 am on Feb 8, 2013 (gmt 0) | <left></left> is not a valid HTML element. Most browsers default to blue links, so you probably have some stylesheet that is defining them to be gray instead. You should look in your existing CSS for something like one of the following: a { ... } If you want to target just the links within the div that has class box, you could add the follow to your CSS: Note, though, that if you have other style rules that have a greater specificity, then that might over ride this style.
|
|
|