scottybwoy Posted March 25, 2008 Share Posted March 25, 2008 Hi, I have some h3 tags that are given one style across my site but in one section I don't want them to have a bottom border which I have set elsewhere. No matter where I set border to none it just won't work. Is there some sort of protection on this element or have I just not done it right somewhere? To ensure I have the right selector I have given it its own class : <h3 class='noBorder'> And have put the css for it as the last style to be applied : .noBorder { border-style: none; } Thanks for your help. Quote Link to comment Share on other sites More sharing options...
wildteen88 Posted March 25, 2008 Share Posted March 25, 2008 That should work, aslong the .noBoarder selector is set after the h3 selector, eg: h3 { /* css for <h3></h3> tags } h3.noBorder { border-style: none; } if it still doesnt work then re-set the boarder: border: 0px solid #FFF; Quote Link to comment Share on other sites More sharing options...
scottybwoy Posted March 25, 2008 Author Share Posted March 25, 2008 got it, had to do #content .products h3 { Quote Link to comment Share on other sites More sharing options...
haku Posted March 26, 2008 Share Posted March 26, 2008 You may want to read up a bit on CSS inheritance to prevent these types of situations. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.