text-decoration: none not working in IE

Discussion in 'CSS' started by cheezile, Jul 26, 2009.

  1. #1
    Hey everyone I used text-decoration none for my links, however it doesn't work in IE. The weird thing is that I used text-decoration: none on other links, however those work perfectly. Here is the code below,

    <code>
    h2 a {
    text-decoration: none;
    }

    h2 a:hover {
    text-decoration: none;
    }
    </code>
    Any suggestions?
     
    cheezile, Jul 26, 2009 IP
  2. qazu

    qazu Well-Known Member

    Messages:
    1,834
    Likes Received:
    62
    Best Answers:
    0
    Trophy Points:
    165
    #2
    text-decoration: none works quite fine in IE6, IE7, and IE8. It sounds like you've got another a {} property in your style sheet after h2 a {} that is being applied. CSS applies styles sequentially one after the other so the last style defined for a {} will be applied. Try placing h2 a {} at the end of the style sheet and see what happens
     
    qazu, Jul 26, 2009 IP
  3. cheezile

    cheezile Peon

    Messages:
    16
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    so do you think i should do an inline style on h2 to fix the problem?
    edit: i did that and it worked thanks for your help
     
    cheezile, Jul 26, 2009 IP