Citations with added RDFa: Difference between revisions

From The Digital Classicist Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 6: Line 6:


Focusing just on the a element, the following RDFa provides additional levels of detail:
Focusing just on the a element, the following RDFa provides additional levels of detail:
 
 
   
  <span rel="dc:references">
   <a class="citation"
   <a class="citation"
       title="Homer Iliad 2.494"
       title="Homer Iliad 2.494"
      rel="dc:references"
       href="http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494"
       href="http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494"
      typeof="dc:Text"
       >Il. 2.494-759</a>
       >Il. 2.494-759</a>
   </span>
   </span>
Line 18: Line 17:


Assuming this snippet is found with a document with the URI http://example.org/article01 that contains the necessary prefix declaration, it produces the following RDF in Turtle format:
Assuming this snippet is found with a document with the URI http://example.org/article01 that contains the necessary prefix declaration, it produces the following RDF in Turtle format:
@prefix dc: <http://purl.org/dc/terms/> .
<http://example.org/article01>
    dc:references <http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494> ;


[[category:citation_in_digital_scholarship]]
[[category:citation_in_digital_scholarship]]

Revision as of 19:10, 21 September 2010

The page Citation_in_digital_scholarship describes a convention for indicating citations that relies on the 'class' and 'title' attributes when implemented in (x)html. This page describes the extension of that convention to encompass adding RDFa to conformant citations.

Sample sentence: In the so-called "Catalog of Ships" (Il. 2.494-759), Homer lists the number of ships contributed by the Greeks and their allies.

With citation markup added: In the so-called "Catalog of Ships" (<a class="citation" title="Homer Iliad 2.494" href="http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494">Il. 2.494-759</a>), Homer lists the number of ships contributed by the Greeks and their allies.

Focusing just on the a element, the following RDFa provides additional levels of detail:


 <a class="citation"
     title="Homer Iliad 2.494"
     rel="dc:references"
     href="http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494"
      >Il. 2.494-759</a>
 


Assuming this snippet is found with a document with the URI http://example.org/article01 that contains the necessary prefix declaration, it produces the following RDF in Turtle format:

@prefix dc: <http://purl.org/dc/terms/> .
<http://example.org/article01>
   dc:references <http://perseus.uchicago.edu/perseus-cgi/citequery3.pl?dbname=GreekTexts&query=Hom.%20Il.%202.494> ;