Fixes to TRIU1 and MIDD17, and implementation of linking to fragments in other docs
Posted by mholmes on 09 Aug 2012 in Activity log, Encoding Notes
As part of fixing the missing text in links in MIDD17, I tested and fixed the system for implementing links from one document to a fragment of another. This is basically how it works:
If you want to link from one document (say MIDD17) to another (say TRIU1), you can link to the whole document using mol:TRIU. However, sometimes you might want to link to a specific part of the TRIU1 document (which is a multi-text document). You can link to a specific <div>
in the target document like this:
- First, give the
<div>
in the target document its own@xml:id
. For instance, we might want to link to the "Grocer's Company" section of the TRIU1 document, so we find the div that contains that section, and give it an@xml:id
. Our convention is that an @xml:id for a section in a target document should be created with a prefix that consists of the main document id (TRIU1) and an underscore. So we do this:<div xml:id="TRIU1_grocers">
. - In the document where you want to put the link, construct the link as follows:
<ref target="mol:TRIU1#TRIU1_grocers">
. In other words, mol: + the document id + # + the div id.
Links constructed like this are now working on the site (see MIDD17 links to TRIU1 for examples).