[uf-discuss] Re: XFN is getting smoked by FOAF

Toby A Inkster mail at tobyinkster.co.uk
Tue Mar 11 12:26:42 PST 2008


Tom Morris wrote:

> It's not a choice - you can use both, and you can extend your FOAF
> with other predicate


Indeed. One could even use XFN with FOAF:

	<rdf:RDF
	    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
	    xmlns:xfn="http://gmpg.org/xfn/11#"
	    xmlns:foaf="http://xmlns.com/foaf/0.1/">
		<foaf:Person rdf:nodeID="p1">
		    <foaf:name>Alice</foaf:name>
		    <foaf:knows rdf:nodeID="p2"/>
		    <xfn:friend rdf:nodeID="p2"/>
		</foaf:Person>
		<foaf:Person rdf:nodeID="p2">
		    <foaf:name>Bob</foaf:name>
		    <foaf:knows rdf:nodeID="p1"/>
		    <xfn:friend rdf:nodeID="p1"/>
		</foaf:Person>
	</rdf:RDF>

Going the other way around:

	<p about="#alice">Alice <a rel="foaf:knows friend" href="#bob">Bob</ 
a>.</p>
	<p about="#bob">Bob <a rel="foaf:knows friend" href="#alice">Alice</ 
a>.</p>

-- 
Toby A Inkster
<mailto:mail at tobyinkster.co.uk>
<http://tobyinkster.co.uk>


More information about the microformats-discuss mailing list