aeroswat Posted July 14, 2010 Share Posted July 14, 2010 I am trying to make my active link be a different color (orange) But it's always defaulting to the navmenu li a definition. What can I do to change this behavior? menu.css #navmenu{ border: 1px solid black; border-bottom-width: 0; width: 175px; } #navmenu ul{ margin: 0; padding: 0; list-style-type: none; font: normal 90% 'Trebuchet MS', 'Lucida Grande', Arial, sans-serif; } #navmenu li a{ display: block; padding: 3px 0; padding-left: 9px; width: 159px; /*185px minus all left/right paddings and margins*/ text-decoration: none; color: white; background-color: #2175bc; border-bottom: 1px solid #90bade; border-left: 7px solid #1958b7; } a#activemenu{ background-color: #FFAA33; border-left-color: #FF0000; } * html #navmenu li a{ /*IE only */ width: 187px; /*IE 5*/ width: 159px; /*185px minus all left/right paddings and margins*/ } #navmenu li a:hover { background-color: #2586d7; border-left-color: #1c64d1; } #navmenu div.menutitle{ color: white; border-bottom: 1px solid black; padding: 1px 0; padding-left: 5px; background-color: black; font: bold 90% 'Trebuchet MS', 'Lucida Grande', Arial, sans-serif; } index.php <div id="navmenu"> <div class="menutitle">Navigation</div> <ul> <li id="activemenu"><a id="activemenu" href="index.php">Home</a></li> <li><a href="location.php">Location</a></li> <li><a href="prices.php">Prices</a></li> <li><a href="contact.php">Equipment</a></li> <li><a href="contact.php">What to Bring</a></li> <li><a href="contact.php">Contact Us</a></li> </ul> <div class="menutitle">Links</div> <ul> <li><a href="linkgoeshere">Weather Forecast</a></li> <li><a href="linkgoeshere">River Height</a></li> </ul> </div> Link to comment https://forums.phpfreaks.com/topic/207718-why-is-this-not-being-overwritten/ Share on other sites More sharing options...
aeroswat Posted July 14, 2010 Author Share Posted July 14, 2010 Zzz... I forgot the li in that activemenu id definition Thanks Link to comment https://forums.phpfreaks.com/topic/207718-why-is-this-not-being-overwritten/#findComment-1085873 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.