Loading ...
Sorry, an error occurred while loading the content.

[jslint] Re: CSS 3 selectors.

Expand Messages
  • pauanyu
    ... Thanks for the link. I took some quick glances at it and didn t notice any mention that CLASS must begin with letters, numbers, or the underscore. I did
    Message 1 of 9 , Jul 26 5:39 PM
    • 0 Attachment
      --- In jslint_com@yahoogroups.com, mnewton32@... wrote:
      >
      > They are allowed to contain almost any character, but can only start with letters, numbers, or the underscore I believe. It's there in the (very readable) HTML 4.01 spec. http://w3.org/TR/html4 if I recall correctly.
      >
      > Sent from my BlackBerry device on the Rogers Wireless Network
      >

      Thanks for the link. I took some quick glances at it and didn't notice any mention that CLASS must begin with letters, numbers, or the underscore. I did find this:

      ID and NAME tokens must begin with a letter ([A-Za-z]) and may be followed by any number of letters, digits ([0-9]), hyphens ("-"), underscores ("_"), colons (":"), and periods (".").

      Note that is for ID and NAME, not CLASS. In addition, because CLASS is a cdata-list, it can also contain unescaped HTML entities as well.

      If I'm reading this properly, that means CLASS can contain *any* characters, separated by whitespace.

      Here's the relevant link about CDATA:
      http://www.w3.org/TR/html4/types.html#type-cdata
    Your message has been successfully submitted and would be delivered to recipients shortly.