Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 6 of 6
  1. #1
    Senior Member tekp's Avatar
    Join Date
    Jan 2004
    Location
    A small village near a small city near a small cit
    Posts
    918
    Member #
    4667
    Liked
    1 times
    I have this section of code:

    .left li a:link,
    .left li a:active,
    .left li a:visited {
    padding:0px 0px 0px 13px;
    background-image:url('../../../images/layout/blue/li.gif');
    background-repeat:no-repeat;
    background-position:0 -3;
    text-decoration:none;
    color:#899FB4;
    }

    .left li a:hover {
    background-image:url('../../../images/layout/blue/li-filled.gif');
    color:#A8B6C6;
    }
    and the validator is shouting at me for it:

    Line: 0 Context : .left li a:link , .left li a:active , .left li a:visited

    Invalid number : background-positionToo many values or values are not recognized : 0 -3
    See the actual page here.


    Can anybody tell me what ive done wrong? can you not hvae negative values or something?
    tekp :cheeky: tekponline.com

  2.  

  3. #2
    Senior Member Brak's Avatar
    Join Date
    Apr 2003
    Location
    San Francisco, CA
    Posts
    3,413
    Member #
    1217
    Liked
    2 times
    You can definately have negative values. The issue is... UNITS!!

    background-position:0 -3px;

    It needs to know, em, px, pts, etc.
    Kyle Neath: Rockstar extraordinare
    The blog | The poetry site | The Spore site

  4. #3
    Senior Member teal's Avatar
    Join Date
    Dec 2003
    Posts
    247
    Member #
    4319
    Also, try li.left instead of .left li . . that is correct class syntax.
    The aseudo stuff goes after a comma "," as well, to seperate it as a second clause.
    Whoth steps forth to mock the teal? Whom couldst say a color superior!

    Proclamith me, it cannot be done.

  5. #4
    Senior Member Brak's Avatar
    Join Date
    Apr 2003
    Location
    San Francisco, CA
    Posts
    3,413
    Member #
    1217
    Liked
    2 times
    hmm, not quite teal.

    You see, he's saying "The a:hover inside the li inside the class left" hence .left li a:hover.

    li.left, a:hover would denote the two separate instances of a:hover and an li with the class left.
    Kyle Neath: Rockstar extraordinare
    The blog | The poetry site | The Spore site

  6. #5
    Senior Member teal's Avatar
    Join Date
    Dec 2003
    Posts
    247
    Member #
    4319
    Ah. Learn a new thing every day, I did not know you could do that.
    Whoth steps forth to mock the teal? Whom couldst say a color superior!

    Proclamith me, it cannot be done.

  7. #6
    Senior Member tekp's Avatar
    Join Date
    Jan 2004
    Location
    A small village near a small city near a small cit
    Posts
    918
    Member #
    4667
    Liked
    1 times
    Yup Braks right, thanks anyway teal!

    Thanks Brak, it's fixed now.
    tekp :cheeky: tekponline.com


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 09:55 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com