HTML and CSS Reference
In-Depth Information
(X)HTML+RDFa
The need for publishing semantically meaningful structured data, such as metadata in RDFa, is not recent. RDFa in
XHTML became a World Wide Web Consortium (W3C) Recommendation on 14 October, 2008 [63]. XHTML+RDFa
(Extensible Hypertext Markup Language + Resource Description Framework in attributes) is an extended version
of the XHTML markup language for supporting RDF through a collection of attributes and processing rules in the
form of well-formed XML documents. This combination is one of the most advanced markup codes. XHTML+RDFa
provides the option to develop Semantic Web content by embedding rich semantic markup. Version 1.1 of the
language is a superset of XHTML 1.1, integrating the attributes according to RDFa Core 1.1. In other words, it is
RDFa support through XHTML Modularization. The RDFa Core 1.1 specification describes how attributes can be
used to express structured data in any markup language, with an emphasis on HTML (instead of XHTML), SVG, the
Open Document Format, and other web-enabled document formats [64]. If the host language is XHTML, it is called
XHTML+RDFa 1.1 [65].
The RDFa markup in XHTML+RDFa reuses the markup code, thus eliminating the need for unnecessary
duplications. XHTML+RDFa can provide machine-readable metadata within the markup code, which makes
additional user functionalities available. Most important of all, actions can be performed automatically that enable
up-to-date publishing, structured searches, and sharing [66].
XHTML+RDFa has never been widely distributed, mainly because of the lack of support in authoring tools and
content management systems [67] and because web designers are not familiar with RDFa. Although the specification
HTML+RDFa 1.1 is primarily an extension of HTML5, it describes rules and guidelines for applying RDFa, not only in
HTML5 but also in HTML 4.01 and XHTML5 [68].
Listing 3-62 presents an XHTML+RDFa skeleton document.
Listing 3-62. An XHTML+RDFa Skeleton Document with an Additional Namespace
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML+RDFa 1.0//EN"
" http://www.w3.org/MarkUp/DTD/xhtml-rdfa-1.dtd " >
<html version="XHTML+RDFa 1.0"
xmlns=" http://www.w3.org/1999/xhtml "
xmlns:foaf=" http://xmlns.com/foaf/0.1/ " xml:lang="en">
<head>
<title>An XHTML+RDF example</title>
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
</head>
<body>
<p>This is a paragraph with semantic content. It was written by
<span about="#smith" typeof="foaf:person" property="foaf:name">John Smith</span>.
</p>
</body>
</html>
The RDFa notation is described in Chapter 7.
XHTML-Print
XHTML-Print is defined in the W3C Recommendation “Modularization of XHTML” [19]. This profile can be used in
printing environments without installing printer-specific drivers. XHTML-Print can also be useful for mobile devices
and low-cost printers that often come with a lack of large (full-page) buffers and that generally print from top-to-
bottom and left-to-right with portrait orientation.
The XHTML-Print document structure is based on the XHTML 1.0 specification. However, application and usage
restrictions apply for images, styles, and forms.
 
Search WWH ::




Custom Search