section ref
authorLuc Moreau <l.moreau@ecs.soton.ac.uk>
Wed, 30 May 2012 22:40:56 +0100
changeset 3088 cdc8abda480a
parent 3087 366b41f3d608
child 3089 01990d34d55a
section ref
model/prov-dm.html
--- a/model/prov-dm.html	Wed May 30 22:15:50 2012 +0100
+++ b/model/prov-dm.html	Wed May 30 22:40:56 2012 +0100
@@ -108,6 +108,27 @@
         });
       }
 
+
+      function updateSectionRefs() {
+
+         $('.section-ref').each(function(index) {
+
+          myhref=$(this).attr('href');
+
+          console.log( "section ref for " + myhref);
+
+
+          mysectionNumber=$(myhref).find('span.secno').text().trim();
+                
+          console.log( "section ref for " + myhref + " " + mysectionNumber);
+
+          $(this).children('span').replaceWith(function(){return $('<span>').append("Section " + mysectionNumber)});
+
+        });
+      }
+
+
+
       $(document).ready(function(){
         // if glossary is in a string:
         $('#glossary_div').html(glossary_string)
@@ -283,6 +304,8 @@
 
           // Add extraReferences to bibliography database
           preProcess: [addExtraReferences],
+
+          postProcess: [updateSectionRefs],
       };
     </script> 
   </head> 
@@ -2161,8 +2184,8 @@
 <div class="anexample" id="anexample-attribution">
 <p>
 Revisiting the example of 
-<a class="sectionRef" href="#section-example-one">TBD</a>,
-we can ascribe <span class="name">tr:WD-prov-dm-20111215</span> to some agents without an explicit activity. The reserved attribute <span class="name">role</span> (see <a  class="sectionRef" href="#term-attribute-role">Section 5.7.4.3</a>) allows for role of the agent in the attribution to be specified.
+<a class="section-ref" href="#section-example-one"><span>TBD</span></a>,
+we can ascribe <span class="name">tr:WD-prov-dm-20111215</span> to some agents without an explicit activity. The reserved attribute <span class="name">role</span> (see <a  class="section-ref" href="#term-attribute-role"><span>TBD</span></a>) allows for role of the agent in the attribution to be specified.
 <pre class="codeexample">
 agent(ex:Paolo, [ prov:type="Person" ])
 agent(ex:Simon, [ prov:type="Person" ])
@@ -2311,7 +2334,7 @@
 </p>
 
 <div class="anexample">
-<p>We refer to the example of <a class="sectionRef" href="#section-example-two">TBD</a>, and specifically to <a  href="#prov-a-document2-top">Figure 3</a>. We can see that there is a path from 
+<p>We refer to the example of <a class="section-ref" href="#section-example-two"><span>TBD</span></a>, and specifically to <a  href="#prov-a-document2-top">Figure 3</a>. We can see that there is a path from 
 <span class="name">tr:WD-prov-dm-20111215</span> to 
 <span class="name">w3:Consortium</span> and to
 <span class="name">process:rec-advance</span>. This is expressed as follows.