Rearrange template so that examples follow groups
authorMo McRoberts <mo.mcroberts@bbc.co.uk>
Wed, 11 Sep 2013 14:34:52 +0100
changeset 35 8233a5e7156b
parent 34 60ee127ff349
child 36 f0974dabb109
Rearrange template so that examples follow groups
2/ODRL20.html
2/template.phtml
--- a/2/ODRL20.html	Tue Sep 10 23:01:54 2013 +0100
+++ b/2/ODRL20.html	Wed Sep 11 14:34:52 2013 +0100
@@ -33,17 +33,17 @@
 <ol class="toc">
 <li><a href="#sec-summary"><span class="secno">1</span> Summary of Terms</a></li>
 <li><a href="#sec-groups"><span class="secno">2</span> Groups</a></li>
-<li><a href="#sec-classes"><span class="secno">3</span> Classes</a></li>
-<li><a href="#sec-properties"><span class="secno">4</span> Properties</a></li>
-<li><a href="#sec-concept-schemes"><span class="secno">5</span> Concept schemes</a></li>
-<li><a href="#sec-concepts"><span class="secno">6</span> Concepts</a></li>
-<li><a href="#sec-named-individuals"><span class="secno">7</span> Named individuals</a></li>
-<li><a href="#sec-examples"><span class="secno">8</span> Examples</a>
+<li><a href="#sec-examples"><span class="secno">3</span> Examples of use</a>
 	<ol class="toc">
-		<li><a href="#sec-example-1"><span class="secno">8.1</span> Set</a></li>
-		<li><a href="#sec-example-2"><span class="secno">8.2</span> Offer</a></li>
+		<li><a href="#sec-example-1"><span class="secno">3.1</span> Set</a></li>
+		<li><a href="#sec-example-2"><span class="secno">3.2</span> Offer</a></li>
 	</ol>
 </li>
+<li><a href="#sec-classes"><span class="secno">4</span> Classes</a></li>
+<li><a href="#sec-properties"><span class="secno">5</span> Properties</a></li>
+<li><a href="#sec-concept-schemes"><span class="secno">6</span> Concept schemes</a></li>
+<li><a href="#sec-concepts"><span class="secno">7</span> Concepts</a></li>
+<li><a href="#sec-named-individuals"><span class="secno">8</span> Named individuals</a></li>
 <li><a href="#sec-examples"><span class="secno">9</span> Acknowledgements</a></li>
 <li><a href="#sec-examples"><span class="secno">10</span> References</a></li>
 </ol>
@@ -96,6 +96,79 @@
 	</tbody>
 </table>
 
+<h2 id="sec-examples">Examples</h2>
+<p>
+	The examples in this section are RDF expressions of the scenarios provided
+	by the <a href="http://www.w3.org/community/odrl/two/model/#section-3">ODRL Version 2.0 Core Model</a>.
+</p>
+<h3 id="sec-example-1">Set</h3>
+<p>
+	The following shows an instance of a <a href="#term-Set">set</a> <a href="#term-Policy">policy</a>. The set shows a policy expression, stating that the <a href="#term-Asset">asset</a>, <code>http//example.com/asset:9898</code>, is the target of the <a href="#term-Permission">permission</a> to <a href="#term-reproduce">reproduce</a> and the <a href="#term-Prohibition">prohibition</a> to <a href="#term-modify">modify</a>.
+</p>
+<pre><code>@base &lt;http://example.com/&gt; .
+@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
+
+&lt;/policy:0099&gt;
+	a odrl:Set;
+	odrl:permission [
+		a odrl:Permission ;
+		odrl:target &lt;/asset:9898&gt; ;
+		odrl:action odrl:reproduce
+	] ;
+	odrl:prohibition [
+		a odrl:Prohibition ;
+		odrl:target &lt;/asset:9898&gt; ;
+		odrl:action odrl:modify
+	] .
+</code></pre>
+<p>Because all of the <a href="#term-Rule">rules</a> associated with this policy have the same target, and do not have any <a href="#term-constraint">constraints</a> or <a href="#term-duty">duties</a> (requirements), one may abbreviate the expression of the policy and use the Dublin Core <a href="http://purl.org/dc/terms/rights">rights</a> or <a href="http://purl.org/dc/terms/license">license</a> predicates to associate the asset with that policy:</p>
+<pre><code>@base &lt;http://example.com/&gt; .
+@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
+@prefix dct: &lt;http://purl.org/dc/terms/&gt; .
+
+&lt;/asset:9898&gt; dct:license &lt;/policy:0099&gt; .
+
+&lt;/policy:0099&gt;
+	a odrl:Set;
+	odrl:permission odrl:reproduce ;
+	odrl:prohibition odrl:modify .
+</code></pre>
+<h3 id="sec-example-2">Offer</h3>
+<p>
+	The following shows the instance of an <a href="#term-Offer">offer</a> policy. The offer contains the music file <code>http//example.com/music:4545</code> that is offered by the <a href="#term-Party">party</a> <code>http//example.com/sony:10</code> with the permissions to <a href="#term-play">play</a> and copy the file. The permission to copy is only granted once. The two permissions are offered in exchange for a payment of <code>AUD$0.50</code>.
+</p>
+<pre><code>@base &lt;http://example.com/&gt; .
+@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
+
+&lt;/policy:0231&gt;
+	a odrl:Offer ;
+	odrl:permission [
+		a odrl:Permission ;
+		odrl:target &lt;/music:4545&gt; ;
+		odrl:assigner &lt;/sony:10&gt; ;
+		odrl:action odrl:play ;
+		odrl:duty _:requirements
+	] ;
+	odrl:permission [
+		odrl:target &lt;/music:4545&gt; ;
+		odrl:assigner &lt;/sony:10&gt; ;
+		odrl:action odrl:copy ;
+		odrl:duty _:requirements ;
+		odrl:constraint [
+			a odrl:Constraint ;
+			odrl:count 1 ;
+			odrl:operator odrl:lteq
+		]
+	] .
+
+_:requirements
+	a odrl:Duty ;
+	odrl:action odrl:pay ;
+	odrl:target &lt;/ubl:AUD0.50&gt; .
+
+&lt;/sony:10&gt; a odrl:Party .
+</code></pre>
+
 <h2 id="sec-classes">Classes</h2>
 <h3 id="term-Asset">Asset</h3
 <p>Asset is anything which can be subject to a policy. Asserting that something the target of a policy implies that it is an Asset.</p>
@@ -1541,78 +1614,6 @@
 </table>
 </div>
 
-<h2 id="sec-examples">Examples</h2>
-<p>
-	The examples in this section are RDF expressions of the scenarios provided
-	by the <a href="http://www.w3.org/community/odrl/two/model/#section-3">ODRL Version 2.0 Core Model</a>.
-</p>
-<h3 id="sec-example-1">Set</h3>
-<p>
-	The following shows an instance of a <a href="#term-Set">set</a> <a href="#term-Policy">policy</a>. The set shows a policy expression, stating that the <a href="#term-Asset">asset</a>, <code>http//example.com/asset:9898</code>, is the target of the <a href="#term-Permission">permission</a> to <a href="#term-reproduce">reproduce</a> and the <a href="#term-Prohibition">prohibition</a> to <a href="#term-modify">modify</a>.
-</p>
-<pre><code>@base &lt;http://example.com/&gt; .
-@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
-
-&lt;/policy:0099&gt;
-	a odrl:Set;
-	odrl:permission [
-		a odrl:Permission ;
-		odrl:target &lt;/asset:9898&gt; ;
-		odrl:action odrl:reproduce
-	] ;
-	odrl:prohibition [
-		a odrl:Prohibition ;
-		odrl:target &lt;/asset:9898&gt; ;
-		odrl:action odrl:modify
-	] .
-</code></pre>
-<p>Because all of the <a href="#term-Rule">rules</a> associated with this policy have the same target, and do not have any <a href="#term-constraint">constraints</a> or <a href="#term-duty">duties</a> (requirements), one may abbreviate the expression of the policy and use the Dublin Core <a href="http://purl.org/dc/terms/rights">rights</a> or <a href="http://purl.org/dc/terms/license">license</a> predicates to associate the asset with that policy:</p>
-<pre><code>@base &lt;http://example.com/&gt; .
-@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
-@prefix dct: &lt;http://purl.org/dc/terms/&gt; .
-
-&lt;/asset:9898&gt; dct:license &lt;/policy:0099&gt; .
-
-&lt;/policy:0099&gt;
-	a odrl:Set;
-	odrl:permission odrl:reproduce ;
-	odrl:prohibition odrl:modify .
-</code></pre>
-<h3 id="sec-example-2">Offer</h3>
-<p>
-	The following shows the instance of an <a href="#term-Offer">offer</a> policy. The offer contains the music file <code>http//example.com/music:4545</code> that is offered by the <a href="#term-Party">party</a> <code>http//example.com/sony:10</code> with the permissions to <a href="#term-play">play</a> and copy the file. The permission to copy is only granted once. The two permissions are offered in exchange for a payment of <code>AUD$0.50</code>.
-</p>
-<pre><code>@base &lt;http://example.com/&gt; .
-@prefix odrl: &lt;http://w3.org/ns/odrl/2/&gt; .
-
-&lt;/policy:0231&gt;
-	a odrl:Offer ;
-	odrl:permission [
-		a odrl:Permission ;
-		odrl:target &lt;/music:4545&gt; ;
-		odrl:assigner &lt;/sony:10&gt; ;
-		odrl:action odrl:play ;
-		odrl:duty _:requirements
-	] ;
-	odrl:permission [
-		odrl:target &lt;/music:4545&gt; ;
-		odrl:assigner &lt;/sony:10&gt; ;
-		odrl:action odrl:copy ;
-		odrl:duty _:requirements ;
-		odrl:constraint [
-			a odrl:Constraint ;
-			odrl:count 1 ;
-			odrl:operator odrl:lteq
-		]
-	] .
-
-_:requirements
-	a odrl:Duty ;
-	odrl:action odrl:pay ;
-	odrl:target &lt;/ubl:AUD0.50&gt; .
-
-&lt;/sony:10&gt; a odrl:Party .
-</code></pre>
 <h2 id="sec-acknowledgements">Acknowledgements</h2>
 <p>
 	The authors gratefully acknowledge feedback and contributions to this document from <a href="http://www.w3.org/community/odrl/">members of the W3C ODRL Community Group</a>.
--- a/2/template.phtml	Tue Sep 10 23:01:54 2013 +0100
+++ b/2/template.phtml	Wed Sep 11 14:34:52 2013 +0100
@@ -26,17 +26,17 @@
 <ol class="toc">
 <li><a href="#sec-summary"><span class="secno">1</span> Summary of Terms</a></li>
 <li><a href="#sec-groups"><span class="secno">2</span> Groups</a></li>
-<li><a href="#sec-classes"><span class="secno">3</span> Classes</a></li>
-<li><a href="#sec-properties"><span class="secno">4</span> Properties</a></li>
-<li><a href="#sec-concept-schemes"><span class="secno">5</span> Concept schemes</a></li>
-<li><a href="#sec-concepts"><span class="secno">6</span> Concepts</a></li>
-<li><a href="#sec-named-individuals"><span class="secno">7</span> Named individuals</a></li>
-<li><a href="#sec-examples"><span class="secno">8</span> Examples</a>
+<li><a href="#sec-examples"><span class="secno">3</span> Examples of use</a>
 	<ol class="toc">
-		<li><a href="#sec-example-1"><span class="secno">8.1</span> Set</a></li>
-		<li><a href="#sec-example-2"><span class="secno">8.2</span> Offer</a></li>
+		<li><a href="#sec-example-1"><span class="secno">3.1</span> Set</a></li>
+		<li><a href="#sec-example-2"><span class="secno">3.2</span> Offer</a></li>
 	</ol>
 </li>
+<li><a href="#sec-classes"><span class="secno">4</span> Classes</a></li>
+<li><a href="#sec-properties"><span class="secno">5</span> Properties</a></li>
+<li><a href="#sec-concept-schemes"><span class="secno">6</span> Concept schemes</a></li>
+<li><a href="#sec-concepts"><span class="secno">7</span> Concepts</a></li>
+<li><a href="#sec-named-individuals"><span class="secno">8</span> Named individuals</a></li>
 <li><a href="#sec-examples"><span class="secno">9</span> Acknowledgements</a></li>
 <li><a href="#sec-examples"><span class="secno">10</span> References</a></li>
 </ol>
@@ -88,14 +88,6 @@
 	</tbody>
 </table>
 
-<?php	
-print $vocab->htmlTerms('Phpspecgen_Class', 'Classes');
-print $vocab->htmlTerms('Phpspecgen_Property', 'Properties');
-print $vocab->htmlTerms('Phpspecgen_ConceptScheme', 'Concept schemes');
-print $vocab->htmlTerms('Phpspecgen_Concept', 'Concepts');
-print $vocab->htmlTerms('Phpspecgen_Individual', 'Named individuals');
-?>
-
 <h2 id="sec-examples">Examples</h2>
 <p>
 	The examples in this section are RDF expressions of the scenarios provided
@@ -123,6 +115,15 @@
 </p>
 <?php printExample('example2.ttl'); ?>
 
+
+<?php	
+print $vocab->htmlTerms('Phpspecgen_Class', 'Classes');
+print $vocab->htmlTerms('Phpspecgen_Property', 'Properties');
+print $vocab->htmlTerms('Phpspecgen_ConceptScheme', 'Concept schemes');
+print $vocab->htmlTerms('Phpspecgen_Concept', 'Concepts');
+print $vocab->htmlTerms('Phpspecgen_Individual', 'Named individuals');
+?>
+
 <h2 id="sec-acknowledgements">Acknowledgements</h2>
 <p>
 	The authors gratefully acknowledge feedback and contributions to this document from <a href="http://www.w3.org/community/odrl/">members of the W3C ODRL Community Group</a>.