HTML and CSS Reference
In-Depth Information
Optionally, the triples can be displayed in N-Triples format. The colors of nodes, arcs, and text, as well as font size
and orientation, can be set as advanced options.
Validating News Feeds
Since RSS and Atom news feeds should be valid XML documents, care must be taken to provide error-free elements
and well-formed XML structure.
The World Wide Web Consortium runs the W3C Feed Validation Service, for Atom and RSS at http://validator. [9]. Similar to other W3C validators, it provides not only validation by URI but also validation by direct
input. After successful validation, the service provides a “valid RSS” or “valid Atom” logo (depending on the validated
feed), an embedding code, and a text link.
The FEED Validator for Atom and RSS and KML at can also be used to validate
RSS 2.0 as well as Atom 1.0 feeds [10]. Additionally, it validates elements of the blogChannel , dc , itunes , mod_admin ,
mod_syndication , and mod_content 5 namespaces.
Validating CSS
Style sheet validations should be performed according to the CSS level being used. Although valid CSS1 style sheets are
also valid CSS 2.1 style sheets, some CSS1 rulesets should be written with slightly different semantics in CSS 2.1 [11].
Since certain CSS2 features are omitted in CSS 2.1, not all CSS2 styles are valid in CSS 2.1 [12]. Similarly, the new
properties introduced in CSS3 are invalid in earlier CSS versions. Valid CSS style sheets must conform to the grammar
rules of the corresponding version and must contain only at-rules, properties, and property values defined in that
In spite of the relatively wide selection of markup language versions and variants, the document type to be
used for markup validation can usually be selected automatically based on the Document Type Declaration.
However, there is no similar mechanism in CSS, and determining the version of style sheets to be validated is not
so straightforward. First, there is no version declaration in CSS, and second, there is a large overlap between the
vocabularies of different versions, making automatic version detection impossible. Hence, the W3C CSS Validation
Service at [13] validates style sheets against CSS3 by default. The CSS profile
to be used for validation can be overridden or forced manually as an advanced option. For example, if you want to
pass a CSS file to the validator as CSS3, you should construct a URI 6 similar to the one shown in Listing 14-2.
Listing 14-2. Explicitly Selected CSS Profile for Validation
&profile=css3 &usermedium=all&warning=0&lang=en
Similar to the Markup Validation Service, the CSS validator can perform the validation by URI, file upload, or direct
input. The CSS validator can be used primarily to validate external CSS files, but internal styles can also be checked.
However, in the latter case, the (X)HTML document should be validated first with the Markup Validation Service.
The CSS Validation Service supports CSS1, CSS2, CSS 2.1, and CSS3 style sheets, along with other document
profiles. Media types can be selected manually, including all , aural , Braille , embossed , handheld , print ,
projection , screen , TTY , TV , or presentation . The default media type is all . Beyond errors, the validator might
identify warnings as well. Since they might be false positives or the consequence of errors, warnings can be hidden.
content:encoded only
6 Naturally, you can select the profile “CSS level 3” from the drop-down list under “More Options.” However, you need to construct
a URI manually if you want to provide a validation link for your CSS3 button, because the default code assumes CSS 2.1.
Search WWH ::

Custom Search