Link Class Tags

Discussion in 'HTML & Website Design' started by tobydawson13, Dec 3, 2008.

  1. #1
    Hi, I have this code, could I wrap the two class tags together?

    How would I go about doing this?

    <a href="#" class="white" class="TabbedPanelsTab" tabindex="0">FAQ</a>
    HTML:
    Thankyou for your help :)
     
    tobydawson13, Dec 3, 2008 IP
  2. 2advance

    2advance Well-Known Member

    Messages:
    2,614
    Likes Received:
    72
    Best Answers:
    0
    Trophy Points:
    140
    #2
    I think it is not possible to create two classes in a single tag, well, I am not expert in HTML
     
    2advance, Dec 4, 2008 IP
  3. icecubedesigns

    icecubedesigns Peon

    Messages:
    23
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Why dont you write a single class with the required properties and then use that single class?
     
    icecubedesigns, Dec 4, 2008 IP
  4. q7m

    q7m Well-Known Member

    Messages:
    1,178
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    150
    Digital Goods:
    1
    #4
    You can have two classes, but a single class attribute:
    <a href="#" class="white TabbedPanelsTab" tabindex="0">FAQ</a>
    Code (markup):
     
    q7m, Dec 5, 2008 IP
  5. fragin_bastich

    fragin_bastich Guest

    Messages:
    65
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #5
    I'll second that, you can include multiple classes in a single class tag, separated by a space.
     
    fragin_bastich, Dec 5, 2008 IP
  6. hatrick24

    hatrick24 Peon

    Messages:
    43
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    adding a space between two classes in the same attrib would do.
    but also be aware that if there are conflicting properties of the class, the class written at the end will have the resulting change. just for ur info.
     
    hatrick24, Dec 5, 2008 IP
  7. Ownageplocks

    Ownageplocks Peon

    Messages:
    44
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #7
    single classes
     
    Ownageplocks, Dec 6, 2008 IP
  8. Trapped

    Trapped Well-Known Member

    Messages:
    1,832
    Likes Received:
    48
    Best Answers:
    0
    Trophy Points:
    130
    #8
    zeegal has already given the correct answer. That way is possible, browsers read it and it does not break validation either.
     
    Trapped, Dec 6, 2008 IP
  9. tobydawson13

    tobydawson13 Active Member

    Messages:
    645
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    60
    #9
    Thanks Zeegal :)
     
    tobydawson13, Dec 6, 2008 IP