GirlGlam.co.uk Posted July 23, 2011 Share Posted July 23, 2011 Hi There,I will be grateful for any help you can offer. I am using a navigation bar on my website. However the background colour of the link spills into other links on the site. I am told that using an inline css code will stop this from happening however I am not sure how to do this. I will be extremely grateful for any assistance you can offer.Pls see link below of the problem.http://estore.eclipse.net.uk/epages/468933...e=Classic/AntikMany thanks Link to comment Share on other sites More sharing options...
Ingolme Posted July 23, 2011 Share Posted July 23, 2011 If you're using the "a:link" selector then the properties will be applied to every link on the page.Give a class attribute to the links that you want to style and then apply a style to that class.For example: .menu { /* Some CSS code here */} <a class="menu" ... >Link</a> Link to comment Share on other sites More sharing options...
GirlGlam.co.uk Posted July 23, 2011 Author Share Posted July 23, 2011 If you're using the "a:link" selector then the properties will be applied to every link on the page.Give a class attribute to the links that you want to style and then apply a style to that class.For example:.menu { /* Some CSS code here */} <a class="menu" ... >Link</a> Hi thanks for this. I am a complete newbie and dont really understand the tech language used here. Do u think you can break it down a little for me pls. Link to comment Share on other sites More sharing options...
GirlGlam.co.uk Posted July 23, 2011 Author Share Posted July 23, 2011 Hi thanks for this. I am a complete newbie and dont really understand the tech language used here. Do u think you can break it down a little for me pls.this is the code i have been using. Thanks for your help with this.<html><head><style type="text/css">ul{list-style-type:none;margin:0;padding:0;padding-top:6px;padding-bottom:6px;}li{display:inline;}a:link,a:visited{font-weight:normal;color:#FFFFFF;background-color:#98bf21;text-align:center;padding:6px;text-decoration:none;text-transform:uppercase;}a:hover,a:active{background-color:#7A991A;}</style></head><body><ul><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories">Homepage</a></li><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories/Wholesale_Womens_Shoes">Womens Shoes</a></li><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories/Wholesale_Dress_Sandals">Dress & Evening Sandals</a></li><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories/Mens_Formal_Shirts">Wholesale Mens Formal Shirts</a></li><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories/OFFERS">SALE</a></li><li><a href="https://www.hermes-europe.co.uk/tracker.html?trackingNumber=My+tracking+number&Postcode=Delivery+postcode">Track My Order</a></li><li><a href="http://girlglam.co.uk/epages/950000401.sf/en_GB/?ObjectPath=/Shops/950000401/Categories/Forum">FORUM</a></li></ul> Link to comment Share on other sites More sharing options...
Ingolme Posted July 23, 2011 Share Posted July 23, 2011 This part of the CSS tutorial should help you: http://w3schools.com/css/css_id_class.aspYou probably should look through the whole tutorial. There aren't any questions you've asked that aren't answered in the tutorial. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.