Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New to the CF scene
    Join Date
    Nov 2002
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    different style links

    hey,

    I was just wondering how you would make a multi-style links. meaning i'd like to have a different :active, :link, :visited, :hover in one area and another style in one area??

    I saw an example of that here but i can't find it!

    It looked something like

    #link1:active { color:green; text-decoration: none; ...etc }

    or

    #link1:active, link1:hover { color:green; text-decoration: none; ...etc }

    any help would be appreciated

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    North East England
    Posts
    853
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You can do it using classes:

    a.style1:hover{color: #003}
    a.style2:hover{color: #030}

    <a class="style1" href="http://">link</a>
    <a class="style2" href="http://">link</a>
    [+] Computer/PC issues [+] Silverpaw3D
    ------------------------------------------------
    Never buy a dwarf with learning disabilities...

    ...it's not big, and it's not clever.

  • #3
    New to the CF scene
    Join Date
    Nov 2002
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    kool!!

    ...thx a bunch!!

  • #4
    New Coder
    Join Date
    Jul 2002
    Posts
    47
    Thanks
    0
    Thanked 0 Times in 0 Posts
    or you can give a div a class and it will affect all the links within that div


    <style>
    .div1 a:link {color: #ff0000}
    .div1 a:visited {color: #0000ff}
    .div1 a:hover {background: #66ff66}
    </style>

    <div class="div1">
    Your links here
    </div>


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •