XHTML
<?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 xmlns="http://www.w3.org/1999/xhtml"
xmlns:foaf="http://xmlns.com/foaf/0.1/">
<head>
<title>Test 0046</title>
</head>
<body>
<div rel="foaf:knows" instanceof="foaf:Person">
<p property="foaf:name">John Doe</p>
</div>
</body>
</html>
Triples (N3 format)
@prefix _5: <http://www.w3.org/2006/07/SWD/RDFa/testsuite/xhtml1-testcases/0046.>.
@prefix foaf: <http://xmlns.com/foaf/0.1/>.
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>.
_5:xhtml foaf:knows [ a foaf:Person;
foaf:name "John Doe"].
SPARQL (FAILED)
ASK WHERE {
<http://www.w3.org/2006/07/SWD/RDFa/testsuite/xhtml1-testcases/0046.xhtml> <http://xmlns.com/foaf/0.1/knows> _:x .
_:x <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .
_:x <http://xmlns.com/foaf/0.1/name> "John Doe" .
}