Index: /documentation/trunk/tutorials/xml-source/tutorial_en.xml
===================================================================
--- /documentation/trunk/tutorials/xml-source/tutorial_en.xml	(revision 34528)
+++ /documentation/trunk/tutorials/xml-source/tutorial_en.xml	(revision 34529)
@@ -2012,5 +2012,5 @@
 </MajorVersion>
 <MajorVersion number="3">
-<Text id="assoc-files-24b">The above change to the browse format statement, adds the equivalent document icon (a PDF icon in this case) next to the source icon (Word icon) for general classifiers. But the Titles classifier has its own separate format statement, listed as "C1 List" in <AutoText key="glidict::CDM.FormatManager.Feature"/>. So the same change indicated above needs to also be made to "C1 List" format statement. After doing so, preview the collection and browse the collection either by Titles or by Filenames.</Text>  
+<Text id="assoc-files-24b">The above change to the browse format statement, adds the equivalent document icon (a PDF icon in this case) next to the source icon (Word icon) for general classifiers. Preview the collection and browse the collection either by Titles or by Filenames.</Text>  
 </MajorVersion>  
 <Text id="assoc-files-24a">Preview the collection.</Text>
@@ -4010,4 +4010,5 @@
 <Text id="0690a"><MajorVersion number="2">Refresh in the web browser to view</MajorVersion><MajorVersion number="3"><b>Preview</b></MajorVersion> the new <MajorVersion number="2"><AutoText key="coredm::_Global:labelTitle_"/></MajorVersion><MajorVersion number="3"><AutoText key="gs3::metadata_names::Title.buttonname" /></MajorVersion> list.</Text>
 <Text id="0687c">As a consequence of using the <AutoText text="bookshelf_type"/> option of the <AutoText text="List"/> classifier, bookshelf icons appear when titles are browsed. This revised format statement has the effect of specifying in brackets how many items are contained within a bookshelf<MajorVersion number="3"> for classifier nodes</MajorVersion>. <MajorVersion number="2">It works by exploiting the fact that only bookshelf icons define <Format>[numleafdocs]</Format> metadata.</MajorVersion> For document nodes, Title is not displayed. Instead, Volume, Number and Date information are displayed.</Text>
+<Text id="0687d">You may notice that the <AutoText text="Titles"/> browser shows the volume numbers in inverse order. To correct this, in the <AutoText key="glidict::GUI.Design"/> Pane, under <AutoText key="glidict::CDM.GUI.Classifiers"/>, configure the <AutoText text="titles" /> <AutoText text="List" /> classifier. Tick <AutoText text="sort_leaf_nodes_using"/> and set the metadata to <Format>ex.Volume</Format>. Rebuilding now will ensure the <i>ex.Volume</i> Number of each newspaper are listed in numeric order. This has the effect of also sorting the <i>ex.Number</i> value for each <i>ex.Volume</i>.</Text>
 </NumberedItem>
 <Heading>
@@ -4644,6 +4645,6 @@
 </MajorVersion>
 <MajorVersion number="3">
-  <Text id="oaiserver-22">Greenstone 3's OAI implementation uses the OAI standard for Dublin Core, <AutoText text="oai_dc" type="italics"/>, metadata format. By default, it maps all Dublin Core metadata you may have assigned to your collections into <AutoText text="oai_dc" type="italics"/>. This default mapping is specified in the configurable file <Path>resources\oai\OAIConfig.xml.in</Path>, from which <Path>web\WEB-INF\classes\OAIConfig-oaiserver.xml</Path> is generated. If all (or most) of your collections will be using a different metadata format, you can edit the <Path>resources\oai\OAIConfig.xml.in</Path> file's <Format>elementList</Format> section to create mappings from the metadata fields you're using to the metadata fields in <AutoText text="oai_dc" type="italics"/>.</Text>
-  <Text id="oaiserver-22a">You can also specify mappings at collection level, overriding the mappings in <Format>OAIConfig.xml.in</Format> on a per-collection basis. So if a collection specifies metadata for a different metadata set format from the default mappings in <Format>OAIConfig.xml.in</Format>, adjust the collection's <Path>web\sites\localsite\collect\&lt;collection-name&gt;\etc\collectionConfig.xml</Path> file to tell Greenstone how to map the metadata fields of your chosen metadata set format into the <AutoText text="oai_dc" type="italics"/> Dublin Core metadata set supported by the Greenstone OAI server.</Text>
+  <Text id="oaiserver-22">Greenstone 3's OAI implementation uses the OAI standard for Dublin Core, <AutoText text="oai_dc" type="italics"/>, metadata format. By default, it maps all Dublin Core metadata you may have assigned to your collections into <AutoText text="oai_dc" type="italics"/>. This default mapping is specified in the configurable file <Path>resources\oai\OAIConfig-oaiserver.xml.in</Path>, from which <Path>web\WEB-INF\classes\OAIConfig-oaiserver.xml</Path> is generated. If all (or most) of your collections will be using a different metadata format, you can edit the <Path>resources\oai\OAIConfig-oaiserver.xml.in</Path> file's <Format>elementList</Format> section to create mappings from the metadata fields you're using to the metadata fields in <AutoText text="oai_dc" type="italics"/>.</Text>
+  <Text id="oaiserver-22a">You can also specify mappings at collection level, overriding the mappings in <Format>OAIConfig-oaiserver.xml.in</Format> on a per-collection basis. So if a collection specifies metadata for a different metadata set format from the default mappings in <Format>OAIConfig-oaiserver.xml.in</Format>, adjust the collection's <Path>web\sites\localsite\collect\&lt;collection-name&gt;\etc\collectionConfig.xml</Path> file to tell Greenstone how to map the metadata fields of your chosen metadata set format into the <AutoText text="oai_dc" type="italics"/> Dublin Core metadata set supported by the Greenstone OAI server.</Text>
 <Text id="oaiserver-23">For instance, look in the <b>demo</b> collection's collectionConfig.xml file (<Path>web\sites\localsite\collect\lucene-jdbm-demo\etc\collectionConfig.xml</Path>) and scroll down to the definition for the <Format>OAIPMH</Format> ServiceRack. Look at its <Format>ListMetadataFormats</Format> section containing element mappings, which will explain and provide an example for how to specify such an oai mapping from the <AutoText text="DLS" type="italics"/> metadata format that the <b>demo</b> collection uses, to the Dublin Core (<AutoText text="oai_dc" type="italics"/>) metadata used by Greenstone's OAI server. Its <AutoText key="metadata::dls.Organization"/> metadata is mapped to <AutoText text="oai_dc.publisher"/> using the following line in the collectionConfig.xml configuration file (note the use of case):</Text>
 <Format>&lt;element name=&quot;dc:publisher&quot;&gt;<br />
@@ -4698,8 +4699,8 @@
 <MajorVersion number="3">
 <NumberedItem>
-<Text id="gs-oai-3-3">For this exercise, we will be visiting the <b>Open Archives Validator</b>, for which your OAIserver needs to provide a valid email address. In a text editor, open up your Greenstone installation's <Path>resources\oai\OAIConfig.xml.in</Path> file. Set the value of the <Format>adminEmail</Format> element to the email address where the validation results are to be sent. Also set the OAI <Format>repositoryIdentifier</Format> element. The structure of its value is like a domain name and needs to be of the form of <Format>word-dot-extension</Format>, such as "greenstone.org". For more information on the structure of its value, see <Link>http://www.openarchives.org/OAI/2.0/guidelines-oai-identifier.htm</Link>. (If you wanted to additionally test the behaviour of the ResumptionToken feature against the OAI Validator, you would set the <Format>resumeAfter</Format> element to a low value like 5).</Text> 
-</NumberedItem>
-<NumberedItem>
-<Text id="gs-oai-3-4">The modifications to OAIConfig.xml.in need to be brought into effect, so quit and relaunch the Greenstone 3 server application if it is already running. Otherwise, go to <Menu>Start &rarr; Greenstone &rarr; Greenstone3 Server</Menu> to start it up. When the library home page opens in your browser, change the library suffix in the URL to <Format>oaiserver</Format>, which is the baseURL of your OAI Server and would be of the form <Format>http://domain/greenstone3/oaiserver</Format>. Copy this URL and visit <Link>http://www.openarchives.org/Register/ValidateSite</Link>.</Text>
+<Text id="gs-oai-3-3">For this exercise, we will be visiting the <b>Open Archives Validator</b>, for which your OAIserver needs to provide a valid email address. In a text editor, open up your Greenstone installation's <Path>resources\oai\OAIConfig-oaiserver.xml.in</Path> file. Set the value of the <Format>adminEmail</Format> element to the email address where the validation results are to be sent. Also set the OAI <Format>repositoryIdentifier</Format> element. The structure of its value is like a domain name and needs to be of the form of <Format>word-dot-extension</Format>, such as "greenstone.org". For more information on the structure of its value, see <Link>http://www.openarchives.org/OAI/2.0/guidelines-oai-identifier.htm</Link>. (If you wanted to additionally test the behaviour of the ResumptionToken feature against the OAI Validator, you would set the <Format>resumeAfter</Format> element to a low value like 5).</Text> 
+</NumberedItem>
+<NumberedItem>
+<Text id="gs-oai-3-4">The modifications to OAIConfig-oaiserver.xml.in need to be brought into effect, so quit and relaunch the Greenstone 3 server application if it is already running. Otherwise, go to <Menu>Start &rarr; Greenstone &rarr; Greenstone3 Server</Menu> to start it up. When the library home page opens in your browser, change the library suffix in the URL to <Format>oaiserver</Format>, which is the baseURL of your OAI Server and would be of the form <Format>http://domain/greenstone3/oaiserver</Format>. Copy this URL and visit <Link>http://www.openarchives.org/Register/ValidateSite</Link>.</Text>
 </NumberedItem>
 </MajorVersion>
@@ -4859,5 +4860,5 @@
 </NumberedItem>
 <NumberedItem><Text id="ucp-11">Visit the <Link url="http://www.djvu.org/resources/djvu_digital_vs_super_hero_pdf.php">'DjVu-Digital vs. "Super Hero" PDF' page</Link>. The page compares a PDF sample document to its equivalent DjVu version and provides download links for both.</Text>
-<Text id="ucp-11a">Download their <Link url="http://www.djvu.org/docs/superhero.djvu?djvuopts&amp;zoom=page">sample DjVu document</Link> into your <i>DjVu Collection</i>'s import folder.</Text>
+<Text id="ucp-11a">Download their <Link url="http://www.djvu.org/docs/superhero.djvu?djvuopts&amp;zoom=page">sample DjVu document</Link> into your <i>DjVu Collection</i>'s <b>import</b> folder at <MajorVersion number="2"><Path>Greenstone &rarr; collect &rarr; djvucoll &rarr; import</Path> </MajorVersion><MajorVersion number="3"><Path>Greenstone &rarr; web &rarr; sites &rarr; localsite &rarr; collect &rarr; djvucoll &rarr; import</Path></MajorVersion>.</Text>
 </NumberedItem>
 <NumberedItem><Text id="ucp-12">Back in GLI, in the <b>Collection</b> view of the <AutoText key="glidict::GUI.Gather"/> pane, right click and select <AutoText key="glidict::CollectionPopupMenu.Refresh"/>. You should now see your new document "superhero.djvu" ready to be built.</Text>
@@ -4896,5 +4897,5 @@
 </NumberedItem>
 <Heading><Text id="ucp-24">Processing DjVu documents with the UnknownConverterPlugin</Text></Heading>
-<NumberedItem><Text id="ucp-25">Now that you know how to run the <i>djvutxt</i> conversion tool from the commandline, open up the DjVu Collection in GLI. Go into the <AutoText key="glidict::GUI.Design"/> pane's <AutoText key="glidict::CDM.GUI.Plugins"/> section and add a new <AutoText text="UnknownConverterPlugin"/> instance. (There's already one in the Document Plugin pipeline, but it is not set up for processing djvu files.) Click the <AutoText key="glidict::CDM.PlugInManager.Configure" type="button"/> and set up the plugin as follows:</Text>
+<NumberedItem><Text id="ucp-25">Now that you know how to run the <i>djvutxt</i> conversion tool from the commandline, open up the DjVu Collection in GLI. Go into the <AutoText key="glidict::GUI.Design"/> pane's <AutoText key="glidict::CDM.GUI.Plugins"/> section and add a new <AutoText text="UnknownConverterPlugin"/> instance. (There's already one in the Document Plugin pipeline, but it is not set up for processing djvu files.) Press <AutoText key="glidict::CDM.PlugInManager.Configure" type="button"/> and set up the plugin as follows:</Text>
 <BulletList>
 <Bullet><Text id="ucp-26">set its <Format>convert_to</Format> field to <Format>text</Format></Text></Bullet>
@@ -5554,5 +5555,9 @@
 <Text id="ic-08a">Use the terminal to first run the incremental import stage:</Text>
 <Format>perl -S incremental-import.pl -incremental -manifest manifests/add-new-files.xml <MajorVersion number="3">-site localsite</MajorVersion> incremen</Format>
-<Text id="ic-08d">The build log output will end with the messages "3 documents were considered for processing" and "3 documents were processed and included in the collection." So this means just the 3 newly added documents were imported, just as specified by our manifest file add-new-files.xml.</Text>
+<Text id="ic-08d">The build log output will end with the messages</Text> 
+<Format>* 3 documents were considered for processing<br />
+* 3 documents were processed and included in the collection"
+</Format>
+<Text id="ic-08e">This means just the 3 newly added documents were imported, just as specified by our manifest file add-new-files.xml.</Text>
 <Text id="ic-08b">Once that <Format>incremental-import</Format> command has finished running, start off the incremental buildcol stage of the build process:</Text>
 <Format>perl -S incremental-buildcol.pl -activate <MajorVersion number="3">-site localsite</MajorVersion> incremen</Format>
@@ -5902,5 +5907,6 @@
 </NumberedItem>
 <NumberedItem>
-<Text id="hp-05">Restart the server by clicking the <b>Restart Library</b> button in the small Greenstone Server window. (Any time you make changes to an <i>interfaceConfig.xml</i> file, you must restart the server for the changes to take effect.) When the server restarts, look at your home page again. Because <i>home-tutorial.xsl</i> does not yet exist, you should just see unformatted text. </Text>
+<Text id="hp-05">Restart the server by clicking the <b>Restart Library</b> button in the small Greenstone Server window. (Any time you make changes to an <i>interfaceConfig.xml</i> file, you must restart the server for the changes to take effect.) When the server restarts, look at your home page again. Because <i>home-tutorial.xsl</i> does not yet exist, you should see:</Text>
+<Format>Couldn't find and/or load the stylesheet "pages/home-tutorial.xsl" for a=p, sa=home, in collection.</Format>
 </NumberedItem>
 <NumberedItem>
@@ -6157,5 +6163,5 @@
 
 
-<Text id="hp-05">This <i>library servlet</i> defines the default Greenstone3 library (called <b>library</b>). As you can see, the <b>library_name</b> is <i>library</i>, the <b>site_name</b> is <i>localsite</i>, and the <b>interface_name</b> is <i>default</i>. If you look at the next servlet section, you will see that it has a library_name of <i>halftone-library</i>, uses <i>localsite</i> and the interface <i>halftone</i>. If you continue to scroll down, you will see several other library servlets defined. There are also other kinds of servlets, for example, you will see a servlet called <i>oaiserver</i>, which provides the functionality for the OAI server (located at <i>http://localhost:8383/greenstone3/oaiserver</i>).</Text>
+<Text id="hp-05">This <i>library servlet</i> defines the default Greenstone3 library (called <b>library</b>). As you can see, the <b>library_name</b> is <i>library</i>, the <b>site_name</b> is <i>localsite</i>, and the <b>interface_name</b> is <i>default</i>. If you look at the next servlet section, you will see that it has a library_name of <i>halftone-library</i>, uses <i>localsite</i> and the interface <i>halftone</i>. If you continue to scroll down, you will see several other library servlets definitions, albeit inactive as they're commented out. There are also other kinds of de-activeated servlets, such as <i>gateway</i>. These are beyond the scope of this tutorial.</Text>
 </NumberedItem>
 <NumberedItem>
@@ -6542,5 +6548,6 @@
 		<Tab n="2"/>&lt;xsl:variable name="collectionFolder" select="@name"/&gt;<br />
 		<Tab n="2"/>&lt;xsl:variable name="collectionName" select="displayItemList/displayItem[@name='name']"/&gt;<br />
-		<Tab n="2"/>&lt;xsl:variable name="aboutImage" select="displayItemList/displayItem[@name='icon']"/&gt;<br />
+		<Tab n="2"/>&lt;xsl:variable name="homeImage" select="displayItemList/displayItem[@name='icon']"/&gt;<br />
+		<Tab n="2"/>&lt;xsl:variable name="aboutImage" select="displayItemList/displayItem[@name='smallicon']"/&gt;<br />
 		<Tab n="2"/>&lt;xsl:variable name="collDesc" select="displayItemList/displayItem[@name='description']"/&gt;<br />
 		<Tab n="2"/>&lt;xsl:variable name="numDocs" select="metadataList/metadata[@name='numDocs']"/&gt;<br /><br />
@@ -6553,5 +6560,5 @@
 		<Tab n="2"/>&lt;xsl:choose&gt;<br />
 			<Tab n="3"/>&lt;xsl:when test="$collDesc"&gt;<br />
-				<Tab n="4"/>&lt;p class="justify"&gt;&lt;xsl:value-of select="$collDesc"  disable-output-escaping="yes"/&gt;&lt;/p&gt;<br />
+				<Tab n="4"/>&lt;p class="justify"&gt;&lt;xsl:apply-templates select="displayItemList/displayItem[@name='description']"/&gt;&lt;/p&gt;<br />
 			<Tab n="3"/>&lt;/xsl:when&gt;<br />
 			<Tab n="3"/>&lt;xsl:otherwise&gt;<br />
@@ -6631,5 +6638,7 @@
 	<Tab n="3"/>&lt;/head&gt;<br/>
 	<Tab n="3"/>&lt;body&gt;<br/>
-		<Tab n="4"/>&lt;xsl:apply-templates select="/page"/&gt;<br/>
+		<Tab n="4"/>&lt;div class="container" id="gs_content"&gt;
+			<Tab n="5"/>&lt;xsl:apply-templates select="/page"/&gt;<br/>
+		<Tab n="4"/>&lt;/div&gt;
 		<Tab n="4"/>&lt;xsl:call-template name="gs_footer"/&gt;<br/>
 	<Tab n="3"/>&lt;/body&gt;<br/>
@@ -6639,5 +6648,5 @@
 <Text id="ni3-03">Every page in our library uses this template. As you can see, it contains the basic structure of our HTML page. Inside the HTML header, the <b>create-html-header</b> template is called (<Format>&lt;xsl:call-template name="create-html-header"/&gt;</Format>). This is the template in <b>header.xsl</b> we edited in the previous tutorial. Inside the body of the HTML, we use two templates: <b>/page</b> and <b>gs_footer</b>. (The <b>/page</b> template is "applied" instead of called. The reason for this is complex and not relevant to this tutorial.)</Text>
 <Text id="ni3-04"> The <b>/page</b> template is where the content of each individual page is. For the home page, it is the content we just added to <b>home.xsl</b>. Since the <b>perrin</b> interface does not have XSL files for any of the other page types, the content of all of the other pages depends on the default interface: on the collection's about page, it's the collection description; on search pages, it is the query boxes and search results; on document pages it is the document content, etc. </Text>
-<Text id="ni3-04">The <b>gs_footer</b> template is where we will put our page's footer.</Text>
+<Text id="ni3-05">The <b>gs_footer</b> template is where we will put our page's footer.</Text>
 </NumberedItem>
 <NumberedItem>
@@ -6659,5 +6668,11 @@
 </NumberedItem>
 <NumberedItem>
-<Text id="ni3-08">You'll notice that the image slider and the highlighted items are right up against the edge of the page. In <b>main.xsl</b>, replace <Format>&lt;xsl:apply-templates select="/page"/&gt;</Format> with:</Text>
+<Text id="ni3-08">You'll notice that the image slider and the highlighted items are right up against the edge of the page. In <b>main.xsl</b>, replace 
+<Format>
+	<Tab n="2"/>&lt;div class="container" id="gs_content"&gt;<br />
+		<Tab n="3"/>&lt;xsl:apply-templates select="/page"/&gt;<br />
+	<Tab n="2"/>&lt;/div&gt;<br />
+</Format>
+with:</Text>
 <Format>
 	<Tab n="2"/>&lt;div class="wrapper"&gt;<br/>
@@ -7006,5 +7021,5 @@
 </NumberedItem>
 <NumberedItem>
-<Text id="ni3-27">Save and close <b>main.xsl</b> and refresh the web browser to see the top bar. Click the <b>Login</b> button and log in as <b>admin</b> (if you hadn't already changed the password, use the default password of "admin") to see all of the links appear along the top, including links to the <b>Add User</b> page, to the <b>Administration</b> page, and to Logout.</Text>
+<Text id="ni3-28">Save and close <b>main.xsl</b> and refresh the web browser to see the top bar. Click the <b>Login</b> button and log in as <b>admin</b> (if you hadn't already changed the password, use the default password of "admin") to see all of the links appear along the top, including links to the <b>Add User</b> page, to the <b>Administration</b> page, and to Logout.</Text>
 </NumberedItem>
 <Heading>
