Re: The Minimal Set of Attributes for RDFa

Hi Oshani,

The attributes rel, rev, content, href, src already exist in XHTML so if 
you want to base your assumption on any of these, you need to make sure 
the value of rel or rev contain CURIEs. I don't think content, src and 
href are good candidates. The other attributes (about, property, 
resource, datatype, typeof) were introduced by RDFa so if you find any 
of these, they can be a good hint.

Re minimal set, I would think that without any of the attribute rel, 
rev, property you cannot construct proper triples since these define the 
predicates. So if you find any of these attributes with a CURIE as 
value, you're pretty much sure to deal with RDFa. Note also that typeof 
can be used on its own to specify the rdf:type of a given resource 
(which can be the page or a bnode if nothing else is explicitly defined 
in the DOM tree).

Hope that helps,
Stéphane.

Oshani Seneviratne wrote:
> Hi all,
>
> I am trying to figure out an efficient way to determine whether a
> given document has valid RDFa in it or not, without having to parse
> the entire DOM.
>
> So, for example, is it valid to assume that a document *could* be a
> proper RDFa document, if I find a "rel" attribute somewhere in the
> DOM? Are there any other attributes that can be used without a "rel"
> attribute and still be a valid RDFa document?
> In essence, what attributes should comprise this *must have* list of
> attributes for an RDFa document?
>
> Oshani
>
>   

Received on Friday, 29 May 2009 06:39:34 UTC