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 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Nov 2002
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Is this right???

    ......is this right???

    #style1.a:link { color: green; text-decoration: none; }
    #style1.a:active { color: green; text-decoration: none; }
    #style1.a:vistied { color: green; text-decoration: none; }
    #style1.a:hover {background-color: red; text-decoration: underline;}

    #style2.a:link { color: green; text-decoration: none; }
    #style2.a:active { color: green; text-decoration: none; }
    #style2.a:vistied { color: green; text-decoration: none; }
    #style2.a:hover {background-color: red; text-decoration: underline;}


    <a id="style1" href="link1.html>LINK1</a>
    <a id="style2" href="link2.html>LINK2</a>

  • #2
    New Coder
    Join Date
    Jul 2002
    Posts
    47
    Thanks
    0
    Thanked 0 Times in 0 Posts
    a#style1:link { color: green; text-decoration: none; }
    a#style1:active { color: green; text-decoration: none; }
    a#style1:visited { color: green; text-decoration: none; }
    a#style1:hover {background-color: red; text-decoration: underline;}


    <a id="style1" href="link1.html">LINK1</a>

  • #3
    Senior Coder
    Join Date
    Jun 2002
    Location
    41° 8' 52" N -95° 53' 31" W
    Posts
    3,660
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you're concerned about XHTML compatibility, you will want to use classes instead of id's.
    Former ASP Forum Moderator - I'm back!

    If you can teach yourself how to learn, you can learn anything. ;)

  • #4
    New Coder
    Join Date
    Jul 2002
    Posts
    47
    Thanks
    0
    Thanked 0 Times in 0 Posts
    or just use the id selector as intended for a unique markup and you shouldn't have a XHTML problem.

  • #5
    Senior Coder
    Join Date
    Jun 2002
    Location
    41° 8' 52" N -95° 53' 31" W
    Posts
    3,660
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Pardon my ignorance in this area; but can you provide an example? (assuming by unique you don't mean ONLY one instance of a certain "look").

    Otherwise, are not classes the way to go?
    Last edited by whammy; 11-18-2002 at 03:58 AM.
    Former ASP Forum Moderator - I'm back!

    If you can teach yourself how to learn, you can learn anything. ;)

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

    Smile

    thx again peeps...all the example above works great!!


    ..stay tuned for more questions though...im not done


  •  

    Posting Permissions

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