Different "A" CSS styles?

Discussion in 'CSS' started by AndreasB, Feb 20, 2010.

  1. #1
    Hello,

    I'm looking for a way to create several A styles in the same stylesheet.

    If I do:

    a {
    font-weight: bold;​
    }

    it'll change all the links to bold.
    I want to be able to change it depending on what DIV the links are in.
    How may I do this?
     
    AndreasB, Feb 20, 2010 IP
  2. drhowarddrfine

    drhowarddrfine Peon

    Messages:
    5,428
    Likes Received:
    95
    Best Answers:
    7
    Trophy Points:
    0
    #2
    Give the div an id, such as <div id="thisdiv">. Then your css for that div will be #thisdiv a {css stuff}.
     
    drhowarddrfine, Feb 20, 2010 IP