dcsimg
www.webdeveloper.com
Results 1 to 2 of 2

Thread: W3 CSS error Unknown pseudo-element or pseudo-class :valid

  1. #1
    Join Date
    Mar 2013
    Posts
    2

    W3 CSS error Unknown pseudo-element or pseudo-class :valid

    Hallo everyone,
    what correction do i need here to validate in W3C CSS...In my book that's how it was written.


    CODE]
    input:focus:valid
    {
    background: rgb(220,255,220) url(okay.png) bottom right no-repeat;
    -o-background-size: contain;
    -moz-background-size: contain;
    -webkit-background-size: contain;
    background-size: contain;
    }
    input:focus:invalid
    {
    background: rgb(255,232,233) url(warning.png) bottom right no-repeat;
    -o-background-size: contain;
    -moz-background-size: contain;
    -webkit-background-size: contain;
    background-size: contain;
    }
    [/CODE]

    the error in W3C CSS are
    137 Unknown pseudo-element or pseudo-class :valid
    145 Unknown pseudo-element or pseudo-class :invalid

    help would be greatly appreciated
    thanks in advance

  2. #2
    Join Date
    Dec 2012
    Posts
    8
    A starting point

    3.4. Pseudo-classes

    The pseudo-class concept is introduced to permit selection based on information that lies outside of the document tree or that cannot be expressed using the other simple selectors.

    A pseudo-class always consists of a "colon" ( followed by the name of the pseudo-class and, for functional pseudo-classes, by a value between parentheses. White space is optionally allowed between the parentheses and the argument, but not between the pseudo-class name and the parentheses.

    Pseudo-classes are allowed in all compound selectors contained in a selector. Pseudo-classes are allowed anywhere in a compound selector after the leading type selector or (possibly omitted) universal selector. Pseudo-class names are case-insensitive. Some pseudo-classes are mutually exclusive (such that a compound selector containing them, while valid, will never match anything), while others can apply simultaneously to the same element. Pseudo-classes may be dynamic, in the sense that an element can acquire or lose a pseudo-class while a user interacts with the document.

    Dynamic pseudo-classes classify elements on characteristics other than their name, attributes, or content, but rather on characteristics that cannot be deduced from the document tree. They do not appear in or modify the document source or document tree.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles