Changeset 17494 for documentation/trunk/tutorials
- Timestamp:
- 2008-10-08T13:59:48+13:00 (16 years ago)
- Location:
- documentation/trunk/tutorials
- Files:
-
- 4 added
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
documentation/trunk/tutorials/processing/xml-to-index.xsl
r13638 r17494 6 6 <xsl:include href="common.xsl"/> 7 7 8 9 <xsl:variable name="mode"> cd</xsl:variable>8 <!-- set mode to cd/web/wiki depending on where the files will end up --> 9 <xsl:variable name="mode">wiki</xsl:variable> 10 10 11 11 <xsl:template match="TutorialList"> … … 24 24 <xsl:apply-templates select="Tutorial[not(@hidden)]"/> 25 25 </dl> 26 27 <hr/><div style="text-align:center;"><xsl:apply-templates select="/TutorialList/SupplementaryText/Text[@id='copyright']"/></div> 28 26 29 </body> 27 30 </html> -
documentation/trunk/tutorials/processing/xml-to-many-html.xsl
r13638 r17494 7 7 <xsl:output method="html"/> 8 8 <!-- set mode to cd/web/wiki depending on where the files will end up --> 9 <xsl:variable name="mode">w eb</xsl:variable>9 <xsl:variable name="mode">wiki</xsl:variable> 10 10 11 11 <xsl:template match="Tutorial"> … … 25 25 <h2><xsl:apply-templates select="Title/Text"/></h2> 26 26 <xsl:apply-templates select="Content/*"/> 27 28 <hr/><div style="text-align:center;"><xsl:apply-templates select="/TutorialList/SupplementaryText/Text[@id='copyright']"/></div> 29 27 30 </body> 28 31 </html> -
documentation/trunk/tutorials/processing/xml-to-one-html.xsl
r13638 r17494 6 6 <xsl:output method="html"/> 7 7 <!-- set mode to cd/web depending on where the files will end up --> 8 <xsl:variable name="mode">w eb</xsl:variable>8 <xsl:variable name="mode">wiki</xsl:variable> 9 9 10 10 <xsl:template match="TutorialList"> … … 22 22 </dl> 23 23 <xsl:apply-templates select="Tutorial[not(@hidden)]"/> 24 25 <hr/><div style="text-align:center;"><xsl:apply-templates select="SupplementaryText/Text[@id='copyright']"/></div> 24 26 </body> 25 27 </html> … … 35 37 36 38 <xsl:template match="Tutorial"> 39 <div style="page-break-before: always;"> 37 40 <a name="{@id}"/> 38 41 <h2><xsl:apply-templates select="Title/Text"/></h2> … … 42 45 </xsl:call-template> 43 46 </div> 44 <xsl:apply-templates select="Content/*"/> 47 <xsl:apply-templates select="Content/*"/> 45 48 <br/> 46 49 <br/> 50 </div> 47 51 </xsl:template> 48 52 49 53 <xsl:template name="supplementary"> 50 54 <xsl:param name="mode">web</xsl:param> 55 <!-- 51 56 <xsl:call-template name="IndexLink"> 52 57 <xsl:with-param name="mode">combined</xsl:with-param> 53 58 </xsl:call-template> 59 --> 54 60 <xsl:apply-templates select="Prerequisite" mode="combined"/> 55 61 <xsl:if test="SampleFiles"> -
documentation/trunk/tutorials/processing/xml-to-one-workshop.xsl
r13638 r17494 26 26 <xsl:apply-templates select="$manifest/Section" mode="index"/> 27 27 <xsl:apply-templates select="$manifest/Section"/> 28 29 <div style="text-align:center;"><xsl:apply-templates select="/TutorialList/SupplementaryText/Text[@id='copyright']"/></div> 30 28 31 </body> 29 32 </html> 30 </xsl:template> 33 </xsl:template> 34 31 35 32 36 <xsl:template match="Section" mode="index"> 33 37 <xsl:variable name="secnum" select="@number"/> 38 <div style="page-break-after: always;"> 34 39 <h2><a href="#{@id}"><xsl:value-of select="Heading"/></a></h2> 35 40 <xsl:for-each select="TutorialRef|SplitTutorialRef"> … … 39 44 <xsl:if test="self::TutorialRef"> 40 45 <xsl:apply-templates select="$tutorial/Tutorial[@id=$id]" mode="index"> 41 <xsl:with-param name="number"><xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/></xsl:with-param> 46 <xsl:with-param name="number"> 47 <xsl:value-of select="$pos"/> 48 <!--<xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/>--> 49 </xsl:with-param> 42 50 </xsl:apply-templates> 43 51 </xsl:if> 44 52 <xsl:if test="self::SplitTutorialRef"> 45 53 <xsl:apply-templates select="$tutorial/Tutorial[@id=$id]" mode="splitindex"> 46 <xsl:with-param name="number"><xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/></xsl:with-param> 54 <xsl:with-param name="number"> 55 <xsl:value-of select="$pos"/> 56 <!--<xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/>--> 57 </xsl:with-param> 47 58 <xsl:with-param name="split" select="@split"/> 48 59 <xsl:with-param name="type" select="@type"/> … … 53 64 </dl> 54 65 </xsl:for-each> 66 </div> 55 67 </xsl:template> 56 68 … … 64 76 <xsl:if test="self::TutorialRef"> 65 77 <xsl:apply-templates select="$tutorial/Tutorial[@id=$id]"> 66 <xsl:with-param name="number"><xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/></xsl:with-param> 78 <xsl:with-param name="number"> 79 <!-- for just one section --> 80 <xsl:value-of select="$pos"/> 81 <!-- for more than one sections --> 82 <!--<xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/>--> 83 </xsl:with-param> 67 84 </xsl:apply-templates> 68 85 </xsl:if> 69 86 <xsl:if test="self::SplitTutorialRef"> 70 87 <xsl:apply-templates select="$tutorial/Tutorial[@id=$id]" mode="split"> 71 <xsl:with-param name="number"><xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/></xsl:with-param> 88 <xsl:with-param name="number"> 89 <xsl:value-of select="$pos"/> 90 <!--<xsl:value-of select="$secnum"/>.<xsl:value-of select="$pos"/>--> 91 </xsl:with-param> 72 92 <xsl:with-param name="split" select="@split"/> 73 93 <xsl:with-param name="type" select="@type"/> … … 81 101 </xsl:template> 82 102 83 <xsl:template match="Tutorial"> 103 <xsl:template match="Tutorial"> 84 104 <xsl:param name="number"/> 105 <div style="page-break-after: always;"> 85 106 <h2><xsl:value-of select="$number"/>. <xsl:apply-templates select="Title/Text"/></h2> 86 107 <xsl:apply-templates select="Content/*"/> 108 </div> 87 109 </xsl:template> 88 110 … … 104 126 <xsl:param name="beginnotes"/> 105 127 <xsl:param name="endnotes"/> 128 129 <div style="page-break-after: always;"> 106 130 <h2><xsl:value-of select="$number"/>. <xsl:apply-templates select="Title/Text"/><xsl:value-of select="$titleextra"/></h2> 107 131 <xsl:apply-templates select="$beginnotes"/> … … 121 145 </xsl:if> 122 146 <xsl:apply-templates select="$endnotes"/> 147 </div> 123 148 </xsl:template> 124 149 -
documentation/trunk/tutorials/xml-source/tutorial_en.xml
r14060 r17494 3 3 <!ENTITY nbsp " "> 4 4 <!ENTITY rarr "→"> 5 <!ENTITY mdash "—"> 5 <!ENTITY mdash "—"> 6 <!ENTITY copy "©"> 6 7 ]> 7 8 <TutorialList> 8 9 <Title> 9 <Text id="0001">Greenstone tutorial exercises ( October 2006)</Text>10 <Text id="0001">Greenstone tutorial exercises (March 2008)</Text> 10 11 </Title> 11 <Version current="2. 71"/>12 <Version current="2.80"/> 12 13 <SupplementaryText> 13 14 <Text id="title">Greenstone tutorial exercise</Text> … … 19 20 <Text id="wiki">Back to wiki</Text> 20 21 <Text id="print">Print version</Text> 22 <Text id="copyright">Copyright © 2005 2006 2007 2008 by the <Link url="http://www.nzdl.org">New Zealand Digital Library Project</Link> at <Link url="http://www.waikato.ac.nz">the University of Waikato</Link>, New Zealand<br/>Permission is granted to copy, distribute and/or modify this document under the terms of the <Link url="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License</Link>, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled <Link url="http://greenstonewiki.cs.waikato.ac.nz/wiki/gsdoc/GNUFDL.html">âGNU Free Documentation License.â</Link></Text> 21 23 </SupplementaryText> 22 24 <Comment> … … 39 41 </Heading> 40 42 <NumberedItem> 41 <Text id="0085">On inserting the <b>UNAIDS CD-ROM</b>, for many computers installation will begin automatically. If not, "auto-run"—a configurable setting under Windows—is disabled on your computer and you need to double-click <i> setup.exe</i> on the CD-ROM.</Text>43 <Text id="0085">On inserting the <b>UNAIDS CD-ROM</b>, for many computers installation will begin automatically. If not, "auto-run"—a configurable setting under Windows—is disabled on your computer and you need to double-click <i>Setup.exe</i> on the CD-ROM.</Text> 42 44 <Menu> 43 <Text id="0086">My Computer → UNAIDS20 → setup.exe</Text>45 <Text id="0086">My Computer → UNAIDS20 → Setup.exe</Text> 44 46 </Menu> 45 47 </NumberedItem> … … 374 376 <Text id="0193">Installing Greenstone</Text> 375 377 </Title> 376 <Version initial="2.60" current="2. 70w"/>378 <Version initial="2.60" current="2.80"/> 377 379 <Content> 378 380 <Heading> … … 446 448 </Bullet> 447 449 <Bullet> 448 <Text id="0223">"Welcome to the ImageMagick Setup Wizard Click <<b>Next</b>> </Text>450 <Text id="0223">"Welcome to the ImageMagick Setup Wizard Click <<b>Next</b>>"</Text> 449 451 </Bullet> 450 452 <Bullet> … … 485 487 </Title> 486 488 <Prerequisite id="install_greenstone"/> 487 <Version initial="2.60" current="2. 70w"/>489 <Version initial="2.60" current="2.80"/> 488 490 <Content> 489 491 <Comment> … … 589 591 <Text id="0253">Building a small collection of HTML files</Text> 590 592 </Title> 591 <SampleFiles folder=" hobbits"/>592 <Version initial="2.60" current="2. 71"/>593 <SampleFiles folder="simple_html"/> 594 <Version initial="2.60" current="2.80"/> 593 595 <Content> 594 596 <Comment> 595 <Text id="0254">You will need some HTML files, such as those in the <Path> hobbits</Path> folder in <Path>sample_files</Path>.</Text>597 <Text id="0254">You will need some HTML files, such as those in the <Path>simple_html</Path> folder in <Path>sample_files</Path>.</Text> 596 598 </Comment> 597 599 <Heading> … … 601 603 <Text id="0255">Start the Greenstone Librarian Interface:</Text> 602 604 <Menu> 603 <Text id="0255a">Start → All Programs → Greenstone Digital Library Software v2.7 1→ Greenstone Librarian Interface</Text>605 <Text id="0255a">Start → All Programs → Greenstone Digital Library Software v2.74 → Greenstone Librarian Interface</Text> 604 606 </Menu> 605 607 <Comment> … … 615 617 </NumberedItem> 616 618 <NumberedItem> 617 <Text id="0260">You will create a collection based on a few HTML web pages that describe some Hobbits in <i>Lord of the Rings</i>.</Text>619 <Text id="0260">You will create a collection based on a few HTML web pages from the Tudor collection.</Text> 618 620 <Text id="0261">A window pops up. Fill it out with appropriate values—for example,</Text> 619 621 <Indent> 620 <Text id="0261a"><AutoText key="glidict::CDM.General.Collection_Name"/> About Hobbits<br/></Text>621 <Text id="0261b"><AutoText key="glidict::NewCollectionPrompt.Collection_Description"/> A collection about hobbits.</Text>622 <Text id="0261a"><AutoText key="glidict::CDM.General.Collection_Name"/> Small HTML Collection<br/></Text> 623 <Text id="0261b"><AutoText key="glidict::NewCollectionPrompt.Collection_Description"/> A small collection of HTML pages.</Text> 622 624 </Indent> 623 625 <Text id="0262">Leave the setting for <AutoText key="glidict::NewCollectionPrompt.Base_Collection"/> at its default: <AutoText key="glidict::NewCollectionPrompt.NewCollection"/>, and click <AutoText key="glidict::General.OK" type="button"/>.</Text> 624 626 </NumberedItem> 625 627 <NumberedItem> 626 <Text id="0264">Next you must gather together the files that will constitute the collection. A suitable set has been prepared ahead of time in <Path>sample_files → hobbits</Path>. Using the left-hand side of the Librarian Interface's <AutoText key="glidict::GUI.Gather"/> panel, interactively navigate to the <Path>sample_files</Path> folder.</Text>628 <Text id="0264">Next you must gather together the files that will constitute the collection. A suitable set has been prepared ahead of time in <Path>sample_files → simple_html</Path>. Using the left-hand side of the Librarian Interface's <AutoText key="glidict::GUI.Gather"/> panel, interactively navigate to the <Path>sample_files</Path> folder.</Text> 627 629 </NumberedItem> 628 630 <Heading> … … 630 632 </Heading> 631 633 <NumberedItem> 632 <Text id="0265">Now drag the <Path> hobbits</Path> folder from the left-hand side and drop it on the right. The progress bar at the bottom shows some activity. Gradually, duplicates of all the files will appear in the collection panel.</Text>634 <Text id="0265">Now drag the <Path>simple_html</Path> folder from the left-hand side and drop it on the right. The progress bar at the bottom shows some activity. Gradually, duplicates of all the files will appear in the collection panel.</Text> 633 635 <Comment> 634 636 <Text id="0266">You can inspect the files that have been copied by double-clicking on the folder in the right-hand side.</Text> … … 648 650 </NumberedItem> 649 651 <NumberedItem> 650 <Text id="0270">Click the <AutoText key="glidict::CreatePane.Preview_Collection" type="button"/> button to look at the end result. This loads the relevant page into your web browser (starting it up if necessary). Look around the collection and learn about Hobbits!</Text>652 <Text id="0270">Click the <AutoText key="glidict::CreatePane.Preview_Collection" type="button"/> button to look at the end result. This loads the relevant page into your web browser (starting it up if necessary).</Text> 651 653 </NumberedItem> 652 654 <Heading> … … 657 659 </NumberedItem> 658 660 <NumberedItem> 659 <Text id="0272">Presently there is no manually assigned metadata, but the act of building the collection has extracted metadata from the documents. Double click the <Path> hobbits</Path> folder to expand its content. Then single-click <Path>bilbo.html</Path> to display all its metadata in the right-hand side of the panel. The initial fields, starting <AutoText text="dc." type="quoted"/>, are empty. These are Dublin Core metadata fields for manually entered data.</Text>661 <Text id="0272">Presently there is no manually assigned metadata, but the act of building the collection has extracted metadata from the documents. Double click the <Path>simple_html</Path> folder to expand its content. Then single-click <Path>aragon.html</Path> to display all its metadata in the right-hand side of the panel. The initial fields, starting <AutoText text="dc." type="quoted"/>, are empty. These are Dublin Core metadata fields for manually entered data.</Text> 660 662 </NumberedItem> 661 663 <NumberedItem> … … 666 668 </NumberedItem> 667 669 <Heading> 670 <Text id="0275">Viewing the internal links and external links</Text> 671 </Heading> 672 <NumberedItem> 673 <Text id="0275a">Hyperlinks in a Greenstone collection work like this. If the link is to a document that is also in the collection, clicking it takes you to that document in the collection. If the link is to a document that is <i>not</i> in the collection, clicking it takes you to that document on the web.</Text> 674 <Text id="0257b">Open <Path>boleyn.html</Path> and look for the link to <Path>Katharine of Aragon</Path> (in the 5th paragraph of the <Path>Biography</Path> section). This links to a document inside the collection--<Path>aragon.html</Path>. View this document by clicking the link. For an external link, click <Path>letters written by Katharine</Path> (in the <Path>Primary Sources</Path> section). This takes you out on to the web. (A warning message is displayed first. You can also get rid of the warning by add <Format>cgiarg shortname=el argdefault=direct 675 </Format> in the <Path>Greenstone → etc → main.cfg</Path> file)</Text> 676 </NumberedItem> 677 <Heading> 668 678 <Text id="0277">Setting up a shortcut in the Librarian interface</Text> 669 679 </Heading> … … 678 688 </Title> 679 689 <SampleFiles folder="images"/> 680 <Version initial="2.60" current="2. 71"/>690 <Version initial="2.60" current="2.80"/> 681 691 <Content> 682 692 <NumberedItem> … … 700 710 <NumberedItem> 701 711 <Text id="0345">Back in the Librarian Interface, change to the <AutoText key="glidict::GUI.Enrich"/> panel and view the extracted metadata for <Path>Bear.jpg</Path>.</Text> 702 </NumberedItem>703 <Heading>704 <Text id="0347">Adding a metadata set to the collection</Text>705 </Heading>706 <Comment>707 <Text id="0346">We now add our own metadata and use it to give users a new way to browse the collection. We use the Dublin Core metadata set.</Text>708 </Comment>709 <NumberedItem>710 <Text id="0348">The collection (image-e) on which <b>backdrop</b> is based uses only extracted metadata. To add another metadata set, go to the <AutoText key="glidict::GUI.Enrich"/> panel of the Librarian Interface and click the <AutoText key="glidict::EnrichPane.ManageMetadataSets" type="button"/> button underneath the file tree. </Text>711 </NumberedItem>712 <NumberedItem>713 <Text id="0349a">The window that pops up shows the metadata sets currently used by the collection. To add a new one, click <AutoText key="glidict::MetadataSetDialog.Add" type="button"/>.</Text>714 <Text id="0349b">In the window that pops up, select the Dublin Core metadata set from the list of available sets, and click <AutoText key="glidict::MetadataSetDialog.Add_Set" type="button"/>. Close the <AutoText key="glidict::MetadataSetDialog.Title"/> dialog by clicking <AutoText key="glidict::General.Close" type="button"/>.</Text>715 </NumberedItem>716 <NumberedItem>717 <Text id="0351">In the <AutoText key="glidict::GUI.Enrich"/> panel, the metadata for each file now shows the (empty) Dublin Core <AutoText text="dc."/> fields as well as the extracted <AutoText text="ex."/> fields.</Text>718 712 </NumberedItem> 719 713 <Heading> … … 765 759 </Comment> 766 760 <Comment> 767 <Text id="0364">Changes in the <AutoText key="glidict::GUI.Format"/> panel take place immediately and you can see the result straightaway by clicking <b>reload</b> (or <b>refresh</b>) in the web browser. If you modify anything in the <AutoText key="glidict::GUI.Gather"/>, <AutoText key="glidict::GUI.Enrich"/> or <AutoText key="glidict::GUI.Design"/> panels, you will need to rebuild the collection.</Text>761 <Text id="0364">Changes in the <AutoText key="glidict::GUI.Format"/> panel take place immediately and you can see the result straightaway by clicking the <AutoText key="glidict::CreatePane.Preview_Collection"/>. If you modify anything in the <AutoText key="glidict::GUI.Gather"/>, <AutoText key="glidict::GUI.Enrich"/> or <AutoText key="glidict::GUI.Design"/> panels, you will need to rebuild the collection.</Text> 768 762 </Comment> 769 763 <Heading> … … 813 807 </Title> 814 808 <SampleFiles folder="Word_and_PDF"/> 815 <Version initial="2.60" current="2. 71"/>809 <Version initial="2.60" current="2.80"/> 816 810 <Content> 817 811 <Comment> … … 822 816 </NumberedItem> 823 817 <NumberedItem> 824 <Text id="0282">Copy all the files from <Path>sample_files → Word_and_PDF → Documents</Path> into the collection. You can select multiple files by clicking on the first one and shift-clicking on the last one, and drag them all across together. (This is the normal technique of multiple selection.)</Text>818 <Text id="0282">Copy all the .doc, .rtf, .pdf and .ps files from <Path>sample_files → Word_and_PDF → Documents</Path> into the collection. There are 10 files in all: you can select multiple files by clicking on the first one and shift-clicking on the last one, and drag them all across together. (This is the normal technique of multiple selection.)</Text> 825 819 </NumberedItem> 826 820 <NumberedItem> … … 840 834 </NumberedItem> 841 835 <NumberedItem> 842 <Text id="0289c">The extracted Title metadata for some documents is incorrect. For example, the Titles for <Path>pdf01.pdf</Path> and <Path>word03.doc</Path> (the same document in different formats) have missed out the second line. The Title for <Path>pdf03.pdf</Path> has the wrong text altogether. The PostScript documents (<Path>cluster.ps</Path> and <Path>langmodl.ps</Path> do not have extracted titles: what appears in the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list is just the first few characters of the document).</Text>836 <Text id="0289c">The extracted Title metadata for some documents is incorrect. For example, the Titles for <Path>pdf01.pdf</Path> and <Path>word03.doc</Path> (the same document in different formats) have missed out the second line. The Title for <Path>pdf03.pdf</Path> has the wrong text altogether.</Text> 843 837 </NumberedItem> 844 838 <Heading> … … 867 861 </Heading> 868 862 <NumberedItem> 869 <Text id="0304">In the Librarian Interface, look at the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, by clicking on this in the list to the left. Here you can add, configure or remove plugins to be used in the collection. There is no need to remove any plugins, but it will speed up processing a little. In this case we have only Word, PDF, RTF, and PostScript documents, and can remove the <AutoText text="ZIPPlug"/>, <AutoText text="TEXTPlug"/>, <AutoText text="HTMLPlug"/>, <AutoText text="EMAILPlug"/>, <AutoText text="ImagePlug"/>, <AutoText text="ISISPlug"/> and <AutoText text="NULPlug"/> plugins. To delete a plugin, select it and click <AutoText key="glidict::CDM.PlugInManager.Remove" type="button"/>. <AutoText text="GAPlug"/> isrequired for any type of source collection and should not be removed. </Text>863 <Text id="0304">In the Librarian Interface, look at the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, by clicking on this in the list to the left. Here you can add, configure or remove plugins to be used in the collection. There is no need to remove any plugins, but it will speed up processing a little. In this case we have only Word, PDF, RTF, and PostScript documents, and can remove the <AutoText text="ZIPPlug"/>, <AutoText text="TEXTPlug"/>, <AutoText text="HTMLPlug"/>, <AutoText text="EMAILPlug"/>, <AutoText text="ImagePlug"/>, <AutoText text="ISISPlug"/> and <AutoText text="NULPlug"/> plugins. To delete a plugin, select it and click <AutoText key="glidict::CDM.PlugInManager.Remove" type="button"/>. <AutoText text="GAPlug"/> and <AutoText text="MetadataXMLPlug"/> are required for any type of source collection and should not be removed. </Text> 870 864 </NumberedItem> 871 865 <Heading> … … 881 875 <Text id="0312">You can add indexes based on any metadata. Add a new index based on <AutoText key="metadata::dc.Creator"/> by clicking <AutoText key="glidict::CDM.IndexManager.New_Index" type="button"/>. Select <AutoText key="metadata::dc.Creator"/> in the list of metadata, and click <AutoText key="glidict::CDM.IndexManager.Add_Index" type="button"/>.</Text> 882 876 </NumberedItem> 883 <Comment>884 <Text id="0313">The next section is <AutoText key="glidict::CDM.GUI.Subcollections"/>. In this exercise, we will not make any changes to this.</Text>885 </Comment>886 877 <Heading> 887 878 <Text id="0314">Browsing classifiers</Text> … … 902 893 </NumberedItem> 903 894 <NumberedItem> 904 <Text id="0321">Check that all the facilities work properly. There should be three full-text indexes, called <i>text</i>, <i>dc.Title ,ex.Title</i>, and <i>dc.Creator</i>. The <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list should display all the documents to which you have assigned <AutoText key="metadata::dc.Title"/> metadata (and only those documents). The <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list should show one bookshelf for each author you have assigned as <AutoText key="metadata::dc.Creator"/>, and clicking on that bookshelf should take you to all the documents they authored.</Text>895 <Text id="0321">Check that all the facilities work properly. There should be three full-text indexes, called <i>text</i>, <i>dc.Title</i>, and <i>dc.Creator</i>. The <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list should display all the documents to which you have assigned <AutoText key="metadata::dc.Title"/> metadata (and only those documents). The <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list should show one bookshelf for each author you have assigned as <AutoText key="metadata::dc.Creator"/>, and clicking on that bookshelf should take you to all the documents they authored.</Text> 905 896 </NumberedItem> 906 897 <Heading> … … 930 921 <NumberedItem> 931 922 <Text id="0321d-1">If you have already done the <TutorialRef id="enhanced_word"/> exercise, some of the documents will have extracted ex.Creator metadata, and some will have dc.Creator. To use both of these in the Creators classifier, make a similar change to the <AutoText text="AZCompactList"/>: make the <AutoText text="metadata"/> field read <Format><AutoText key="metadata::dc.Creator" type="plain"/><AutoText text=",ex.Creator" type="plain"/></Format>.</Text> 932 <Text id="0321d-2">You may notice that <AutoText text="AZCompactList"/> has two options after the <AutoText text="metadata"/> option: <AutoText text="firstvalueonly"/> and <AutoText text="allvalues"/>. Manually added metadata can be used to replace or enhance automatically extracted metadata, and these options control exactly which pieces of metadata a document is classified by.</Text> 923 <Text id="0321e"><b>Build</b> the collection again and <b>preview</b> it. Now all of the documents should appear in the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list (and extracted Creators should appear in the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list).</Text> 924 </NumberedItem> 925 <Comment> 926 <Text id="0321d-2">We will play around with the format statements and customize the outlook of this collection in the <TutorialRef id="formatting_word_pdf"/> exercise.</Text> 927 </Comment> 928 </Content> 929 </Tutorial> 930 <Tutorial id="formatting_word_pdf"> 931 <Title> 932 <Text id="fw-1">Formatting the Word and PDF collection</Text> 933 </Title> 934 <Prerequisite id="word_pdf_collection"/> 935 <Version initial="2.70w" current="2.80"/> 936 <Content> 937 <Comment> 938 <Text id="fw-1a">In this exercise, we play around with the format statements in the Word and PDF collection.</Text> 939 </Comment> 940 <NumberedItem> 941 <Text id="fw-2">Open the <b>reports</b> collection in the Librarian Interface and go to the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel.</Text> 942 </NumberedItem> 943 <Heading> 944 <Text id="fw-2a">Tidying up the default format statement</Text> 945 </Heading> 946 <NumberedItem> 947 <Text id="fw-3a">In this part of the exercise, we make the format statement simpler without changing the resulting display.</Text> 948 <Text id="fw-3">Greenstone's default format statement is complex because it is designed to produce something reasonable under almost any conditions, and also because for practical reasons it needs to be backwards compatible with legacy collections. For this collection, we don't need all of the complexity.</Text> 949 <Text id="fw-3a-1">Make sure that the <AutoText text="VList"/> format statement is selected in the list of formats.</Text> 950 <Text id="fw-4">The default <AutoText text="VList"/> format statement looks like the following:</Text> 951 <Format> 952 <td valign="top">[link][icon][/link]</td><br/> 953 <td valign="top">[ex.srclink]<highlight>{Or}{[ex.thumbicon],[ex.srcicon]}</highlight>[ex./srclink]</td><br/> 954 <td valign="top">[highlight]<br/> 955 {Or}{[dc.Title],<highlight>[exp.Title]</highlight>,[ex.Title],Untitled}<br/> 956 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td> 957 </Format> 958 <Text id="fw-5">This format statement is the default used for any vertical list, such as search results, classifiers, and document table of contents.</Text> 959 <Text id="fw-6"><Format>{Or}{[ex.thumbicon],[ex.srcicon]}</Format> chooses <i>ex.thumbicon</i> metadata if its there, otherwise chooses <i>ex.srcicon</i> metadata. If neither are present, nothing is displayed. For this collection there is no <i>ex.thumbicon</i> metadata so the choice is not needed.</Text> 960 <Text id="fw-7">Replace <Format>{Or}{[ex.thumbicon],[ex.srcicon]}</Format> (highlighted above) with <Format>[ex.srcicon]</Format>. </Text> 961 <Text id="fw-8">There is no <i>exp.Title</i> metadata, so remove that element from <Format>{Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}</Format>.</Text> 962 <Text id="fw-9">The resulting format statement looks like the following:</Text> 963 <Format> 964 <td valign=top>[link][icon][/link]</td><br/> 965 <td valign=top>[ex.srclink][ex.srcicon][ex./srclink]</td><br/> 966 <td valign=top>[highlight]<br/> 967 {Or}{[dc.Title],[ex.Title],Untitled} 968 [/highlight] {If}{[ex.Source],<br><i>([ex.Source])</i>}</td><br/> 969 </Format> 970 <Text id="fw-10">Preview the collection to make sure the display hasn't changed. You shouldn't notice any difference when looking at search results, classifiers etc. </Text> 971 </NumberedItem> 972 <Heading> 973 <Text id="fw-10a">Linking to Greenstone version or original version of documents</Text> 974 </Heading> 975 <NumberedItem> 976 <Text id="fw-11">For collections with documents that undergo a conversion process during importing (e.g. Word, PDF, PowerPoint documents, but not text, HTML documents), the original file is stored in the collection along with the converted version. The default <AutoText text="VList"/> format statement links to both versions:</Text> 977 <Text id="fw-12"><Format>[ex.link][icon][/ex.link]</Format> links to the Greenstone HTML version, while <Format>[ex.srclink][ex.srcicon][/ex.srclink]</Format> links to the original.</Text> 978 <Text id="fw-13">Choose <AutoText text="SearchVList"/> in <AutoText key="glidict::CDM.GUI.Formats"/> by selecting <AutoText text="Search"/> from the <AutoText key="glidict::CDM.FormatManager.Feature"/> drop down list, and <AutoText text="VList"/> from the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> to add the <AutoText text="SearchVList"/> format statement into the list of assigned formats. Experiment with removing either of the two links from the format statement.</Text> 979 <Text id="fw-13a">To see the results of your changes, preview the collection and do a search. You are making changes to <AutoText text="SearchVList"/>, which means the changes will only apply to search results.</Text> 980 <Text id="fw-13b">Storing and displaying the original allows users to see the correct format, but requires the user to have the relevant program installed. It also increases the size of the collection. The Greenstone version can be viewed in a browser, but may not look as nice.</Text> 981 </NumberedItem> 982 <Heading> 983 <Text id="fw-14a">Making bookshelves show how many items they contain</Text> 984 </Heading> 985 <NumberedItem> 986 <Text id="fw-14">Next, we'll customize the format for the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list. Classifier bookshelves have only a few pieces of metadata to display: <Format>[ex.Title]</Format> and <Format>[numleafdocs]</Format>. Whatever metadata the classifier has been built on, the bookshelf label is always stored as <Format>[ex.Title]</Format>. This is why a Creator is printed out for each bookshelf even though <Format>[dc.Creator]</Format> is not specified in the format statement. <Format>[numleafdocs]</Format> is only defined for bookshelves, so this metadata can be used in an <Format>{If}</Format> statement to make bookshelves and documents display differently in the list.</Text> 987 <Text id="fw-15">Make each bookshelf in the Creator classifier show how many entries it contains. In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText text="CL2 AZCompactList"/> classifier which is based on <AutoText key="metadata::dc.Creator"/> metadata from the <AutoText key="glidict::CDM.FormatManager.Feature"/> drop down list, and <AutoText text="VList"/> from the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click the <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> button to add this format into the list of assigned formats. Note that it gets added as <AutoText text="CL2VList"/> in this list: it is the <AutoText text="VList"/> format for the second (<AutoText text="CL2"/>) classifier.</Text> 988 <Text id="fw15a">Append the following text to the bottom of the format statement:</Text> 989 <Format> 990 {If}{[numleafdocs],<td><i>([numleafdocs])</i></td>} 991 </Format> 992 <Text id="fw-16"><b>Preview</b> the collection. Click on the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list and notice that the bookshelves now display how many documents they contain.</Text> 993 <Text id="fw-17">This revised format statement has the effect of specifying in brackets how many items are contained within a bookshelf. Since only bookshelves define <Format>[numleafdocs]</Format>, only they will display this. By modifying <AutoText text="CL2VList"/> instead of <AutoText text="VList"/>, the change will only apply to the second classifier (Creators).</Text> 994 </NumberedItem> 995 <Heading> 996 <Text id="fw-17a">Displaying multi-valued metadata</Text> 997 </Heading> 998 <NumberedItem> 999 <Text id="fw-18">Next we modify the document entries in the Creator classifier to display all authors. Back in <AutoText key="glidict::CDM.GUI.Formats"/>, select the <AutoText text="CL2VList"/> format in the list of assigned formats. After <Format>{If}{[ex.Source],<br></Format> in the format statement, add <Format>[sibling:dc.Creator]</Format>.</Text> 1000 <Text id="fw-19"><Format>[ex.Source]</Format> is not defined for bookshelves, so can also be used to differentiate bookshelves and documents.</Text> 1001 <Text id="fw-20">The resulting format statement looks like:</Text> 1002 <Format> 1003 <td valign=top>[link][icon][/link]</td><br/> 1004 <td valign=top>[ex.srclink][ex.srcicon][ex./srclink]</td><br/> 1005 <td valign=top>[highlight]<br/> 1006 {Or}{[dc.Title],[ex.Title],Untitled}[/highlight]<br/> 1007 <highlight>{If}{[ex.Source],<br>[sibling:dc.Creator]</highlight><br/> 1008 <i>([ex.Source])</i>}</td><br/> 1009 {If}{[numleafdocs],<td><i>([numleafdocs])</i></td>} 1010 </Format> 1011 <Text id="fw-21">This will display the Greenstone link, the link to the original, then the Title. For bookshelves, it will also display how many documents the bookshelf contains. For documents, it will display all the Authors (Creators), and the source document. <Format>[sibling:dc.Creator]</Format> displays all the Creator metadata for the document, separated by a space (<AutoText text=" " type="quoted"/>), while <Format>[dc.Creator]</Format> displays only the first author. Preview the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list and make sure that all authors are displayed for documents.</Text> 1012 </NumberedItem> 1013 <NumberedItem> 1014 <Text id="fw-22">You can change the separator between the authors. Modify the format statement, and replace <Format>[sibling:dc.Creator]</Format> with <Format>[sibling(All'<br/>'):dc.Creator]</Format>. This will add a new line after each author (<Format><br/></Format> specifies a line break in HTML). Preview the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list.</Text> 1015 <Text id="fw-23">If you have done exercise <TutorialRef id="enhanced_word"/>, the collection will have both dc.Creator and ex.Creator metadata. To display both, you can use </Text> 1016 <Format> 1017 [sibling:dc.Creator] [sibling:ex.Creator] 1018 </Format> 1019 <Text id="fw-23a">To display dc.Creator if it is present, otherwise display ex.Creator, use</Text> 1020 <Format> 1021 {Or}{[sibling:dc.Creator],[sibling:ex.Creator]} 1022 </Format> 1023 </NumberedItem> 1024 <Heading> 1025 <Text id="0321d-1">Advanced multi-valued metadata</Text> 1026 </Heading> 1027 <NumberedItem> 1028 <Text id="0321d-2">You may notice that the <AutoText text="AZCompactList"/> classifier has two options after the <AutoText text="metadata"/> option: <AutoText text="firstvalueonly"/> and <AutoText text="allvalues"/>. Manually added metadata can be used to replace or enhance automatically extracted metadata, and these options control exactly which pieces of metadata a document is classified by.</Text> 933 1029 <Text id="0321d-3">For example, say we have two documents. Document 1 has four Creators specified (dc.Creator = dcA, dc.Creator = dcB, ex.Creator = exA, ex.Creator = exB), while document 2 has three (ex.Creator = exA, ex.Creator = exB, ex.Creator = exC). The following table shows which metadata values each document is classified by, for the different classifier options:</Text> 934 1030 <table> … … 946 1042 </NumberedItem> 947 1043 <NumberedItem> 948 <Text id="0321e"><b>Build</b> the collection again and <b>preview</b> it. Now all of the documents should appear in the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list (and extracted Creators should appear in the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list).</Text> 949 <Text id="0321f">Extracted metadata is unreliable. But it is very cheap! On the other hand, manually assigned metadata is reliable, but expensive. The previous section of this exercise has shown how to aim for the best of both worlds by using extracted metadata but correcting it when it is wrong. While this may not satisfy the professional librarian, it could provide a useful compromise for the music teacher who wants to get their collection together with a minimum of effort.</Text> 950 </NumberedItem> 951 <Heading> 952 <Text id="0295">Branding a collection with an image</Text> 953 </Heading> 954 <NumberedItem> 955 <Text id="0296">Switch back to the <AutoText key="glidict::GUI.Format"/> panel. The first section <AutoText key="glidict::CDM.GUI.General"/> appears. This allows you to modify the values you provided when defining the collection, if desired. You can also brand the collection using a suitable image.</Text> 956 </NumberedItem> 957 <NumberedItem> 958 <Text id="0297">Click on the <AutoText key="glidict::General.Browse" type="button"/> button associated with <AutoText key="glidict::CDM.General.Icon_Collection"/>, and browse to the image <Path>sample_files → Word_and_PDF → wrdpdf.gif</Path> on your computer. When you select this image, Greenstone automatically generates an appropriate URL for the image. <b>Preview</b> the collection: you should see the new image at the top left of the page.</Text> 959 </NumberedItem> 960 </Content> 961 </Tutorial> 962 <Tutorial id="formatting_word_pdf"> 963 <Title> 964 <Text id="fw-1">Formatting the Word and PDF collection</Text> 965 </Title> 966 <Prerequisite id="word_pdf_collection"/> 967 <Version initial="2.70w" current="2.71"/> 968 <Content> 969 <Comment> 970 <Text id="fw-1a">In this exercise, we play around with the format statements in the Word and PDF collection.</Text> 971 </Comment> 972 <NumberedItem> 973 <Text id="fw-2">Open the <b>reports</b> collection in the Librarian Interface and go to the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel.</Text> 974 </NumberedItem> 975 <Heading> 976 <Text id="fw-2a">Tidying up the default format statement</Text> 977 </Heading> 978 <NumberedItem> 979 <Text id="fw-3a">In this part of the exercise, we make the format statement simpler without changing the resulting display.</Text> 980 <Text id="fw-3">Greenstone's default format statement is complex because it is designed to produce something reasonable under almost any conditions, and also because for practical reasons it needs to be backwards compatible with legacy collections. For this collection, we don't need all of the complexity.</Text> 981 <Text id="fw-3a-1">Make sure that the <AutoText text="VList"/> format statement is selected in the list of formats.</Text> 982 <Text id="fw-4">The default <AutoText text="VList"/> format statement looks like the following:</Text> 983 <Format> 984 <td valign="top">[link][icon][/link]</td><br/> 985 <td valign="top">[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]}[ex./srclink]</td><br/> 986 <td valign="top">[highlight]<br/> 987 {Or}{[dls.Title],[dc.Title],[ex.Title],Untitled}<br/> 988 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td> 989 </Format> 990 <Text id="fw-5">This format statement is the default used for any vertical list, such as search results, classifiers, and document table of contents.</Text> 991 <Text id="fw-6"><Format>{Or}{[ex.thumbicon],[ex.srcicon]}</Format> chooses <i>ex.thumbicon</i> metadata if its there, otherwise chooses <i>ex.srcicon</i> metadata. If neither are present, nothing is displayed. For this collection there is no <i>ex.thumbicon</i> metadata so the choice is not needed.</Text> 992 <Text id="fw-7">Replace <Format>{Or}{[ex.thumbicon],[ex.srcicon]}</Format> with <Format>[ex.srcicon]</Format>. </Text> 993 <Text id="fw-8">There is no <i>dls.Title</i> metadata, so remove that element from <Format>{Or}{[dls.Title],[dc.Title],[ex.Title],Untitled}</Format>.</Text> 994 <Text id="fw-9">The resulting format statement looks like the following:</Text> 995 <Format> 996 <td valign=top>[link][icon][/link]</td><br/> 997 <td valign=top>[ex.srclink][ex.srcicon][ex./srclink]</td><br/> 998 <td valign=top>[highlight]<br/> 999 {Or}{[dc.Title],[ex.Title],Untitled}[/highlight] {If}{[ex.Source],<br><i>([ex.Source])</i>}</td><br/> 1000 </Format> 1001 <Text id="fw-10">Preview the collection to make sure the display hasn't changed. You shouldn't notice any difference when looking at search results, classifiers etc. </Text> 1002 </NumberedItem> 1003 <Heading> 1004 <Text id="fw-10a">Linking to Greenstone version or original version of documents</Text> 1005 </Heading> 1006 <NumberedItem> 1007 <Text id="fw-11">For collections with documents that undergo a conversion process during importing (e.g. Word, PDF, PowerPoint documents, but not text, HTML documents), the original file is stored in the collection along with the converted version. The default <AutoText text="VList"/> format statement links to both versions:</Text> 1008 <Text id="fw-12"><Format>[link][icon][/link]</Format> links to the Greenstone HTML version, while <Format>[srclink][srcicon][/srclink]</Format> links to the original.</Text> 1009 <Text id="fw-13">Choose <AutoText text="SearchVList"/> in <AutoText key="glidict::CDM.GUI.Formats"/> by selecting <AutoText text="Search"/> from the <AutoText key="glidict::CDM.FormatManager.Feature"/> drop down list, and <AutoText text="VList"/> from the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> to add the <AutoText text="SearchVList"/> format statement into the list of assigned formats. Experiment with removing either of the two links from the format statement.</Text> 1010 <Text id="fw-13a">To see the results of your changes, preview the collection and do a search. You are making changes to <AutoText text="SearchVList"/>, which means the changes will only apply to search results.</Text> 1011 <Text id="fw-13b">Storing and displaying the original allows users to see the correct format, but requires the user to have the relevant program installed. It also increases the size of the collection. The Greenstone version can be viewed in a browser, but may not look as nice.</Text> 1012 </NumberedItem> 1013 <Heading> 1014 <Text id="fw-14a">Making bookshelves show how many items they contain</Text> 1015 </Heading> 1016 <NumberedItem> 1017 <Text id="fw-14">Next, we'll customize the format for the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list. Classifier bookshelves have only a few pieces of metadata to display: <Format>[ex.Title]</Format> and <Format>[numleafdocs]</Format>. Whatever metadata the classifier has been built on, the bookshelf label is always stored as <Format>[ex.Title]</Format>. This is why a Creator is printed out for each bookshelf even though <Format>[dc.Creator]</Format> is not specified in the format statement. <Format>[numleafdocs]</Format> is only defined for bookshelves, so this metadata can be used in an <Format>{If}</Format> statement to make bookshelves and documents display differently in the list.</Text> 1018 <Text id="fw-15">Make each bookshelf in the Creator classifier show how many entries it contains. In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText text="CL2 AZCompactList"/> classifier which is based on <AutoText key="metadata::dc.Creator"/> metadata from the <AutoText key="glidict::CDM.FormatManager.Feature"/> drop down list, and <AutoText text="VList"/> from the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click the <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> button to add this format into the list of assigned formats. Note that it gets added as <AutoText text="CL2VList"/> in this list: it is the <AutoText text="VList"/> format for the second (<AutoText text="CL2"/>) classifier.</Text> 1019 <Text id="fw15a">Append the following text to the bottom of the format statement:</Text> 1020 <Format> 1021 {If}{[numleafdocs],<td><i>([numleafdocs])</i></td>} 1022 </Format> 1023 <Text id="fw-16"><b>Preview</b> the collection. Click on the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list and notice that the bookshelves now display how many documents they contain.</Text> 1024 <Text id="fw-17">This revised format statement has the effect of specifying in brackets how many items are contained within a bookshelf. Since only bookshelves define <Format>[numleafdocs]</Format>, only they will display this. By modifying <AutoText text="CL2VList"/> instead of <AutoText text="VList"/>, the change will only apply to the second classifier (Creators).</Text> 1025 </NumberedItem> 1026 <Heading> 1027 <Text id="fw-17a">Displaying multi-valued metadata</Text> 1028 </Heading> 1029 <NumberedItem> 1030 <Text id="fw-18">Next we modify the document entries in the Creator classifier to display all authors. Back in <AutoText key="glidict::CDM.GUI.Formats"/>, select the <AutoText text="CL2VList"/> format in the list of assigned formats. After <Format>{If}{[ex.Source],<br></Format> in the format statement, add <Format>[sibling:dc.Creator]</Format>.</Text> 1031 <Text id="fw-19"><Format>[ex.Source]</Format> is not defined for bookshelves, so can also be used to differentiate bookshelves and documents.</Text> 1032 <Text id="fw-20">The resulting format statement looks like:</Text> 1033 <Format> 1034 <td valign=top>[link][icon][/link]</td><br/> 1035 <td valign=top>[ex.srclink][ex.srcicon][ex./srclink]</td><br/> 1036 <td valign=top>[highlight]<br/> 1037 {Or}{[dc.Title],[ex.Title],Untitled}[/highlight]<br/> 1038 {If}{[ex.Source],<br><highlight>[sibling:dc.Creator]</highlight><br/> 1039 <i>([ex.Source])</i>}</td><br/> 1040 {If}{[numleafdocs],<td><i>([numleafdocs])</i></td>} 1041 </Format> 1042 <Text id="fw-21">This will display the Greenstone link, the link to the original, then the Title. For bookshelves, it will also display how many documents the bookshelf contains. For documents, it will display all the Authors (Creators), and the source document. <Format>[sibling:dc.Creator]</Format> displays all the Creator metadata for the document, separated by a space (<AutoText text=" " type="quoted"/>), while <Format>[dc.Creator]</Format> displays only the first author. Preview the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list and make sure that all authors are displayed for documents.</Text> 1043 </NumberedItem> 1044 <NumberedItem> 1045 <Text id="fw-22">You can change the separator between the authors. Modify the format statement, and replace <Format>[sibling:dc.Creator]</Format> with <Format>[sibling(All'<br/>'):dc.Creator]</Format>. This will add a new line after each author (<Format><br/></Format> specifies a line break in HTML). Preview the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list.</Text> 1046 <Text id="fw-23">If you have done exercise <TutorialRef id="enhanced_word"/>, the collection will have both dc.Creator and ex.Creator metadata. To display both, you can use </Text> 1047 <Format> 1048 [sibling:dc.Creator] [sibling:ex.Creator] 1049 </Format> 1050 <Text id="fw-23a">To display dc.Creator if it is present, otherwise display ex.Creator, use</Text> 1051 <Format> 1052 {Or}{[sibling:dc.Creator],[sibling:ex.Creator]} 1053 </Format> 1054 </NumberedItem> 1055 <Heading> 1056 <Text id="fw-24">Opening PDF files with query terms highlighted</Text> 1057 </Heading> 1058 <NumberedItem> 1059 <Text id="fw-24a">Next we'll customize the <AutoText text="SearchVList"/> format statement to highlight the query terms in a PDF file when it is opened from the search result list. This requires Acrobat Reader 7.0 version or higher, and currently only works on a Microsoft Windows platform.</Text> 1060 </NumberedItem> 1061 <NumberedItem> 1062 <Text id="fw-24c">The search terms are kept in the macro variable <AutoText text="_cgiargq_"/>, and we append <AutoText text="#search="_cgiargq_""/> to the end of a PDF file link to pass the query terms to the PDF file.</Text> 1063 <Text id="fw-24d"><AutoText text="PDFPlug"/> renames each PDF file as <AutoText text="doc.pdf"/> and saves it in a unique directory for that document, so we use</Text> 1064 <Format>_httpcollection_/index/assoc/[archivedir]/doc.pdf</Format> 1065 <Text id="fw-24e">to refer to the PDF source file. (However, if you used the <AutoText text="-keep_original_filename"/> option to <AutoText text="PDFPlug"/> when building the collection, the original name of the PDF file is kept, and we use</Text> 1066 <Format>_httpcollection_/index/assoc/[archivedir]/[Source]</Format> 1067 <Text id="fw-24f">instead to locate the PDF source file.)</Text> 1068 </NumberedItem> 1069 <NumberedItem> 1070 <Text id="fw-24g">Select <AutoText text="SearchVList"/> from the list of assigned formats. We need to test whether the file is a PDF file before linking to doc.pdf, using <Format>{If}{[ex.FileFormat] eq 'PDF',,}</Format>. For PDF files, we use the above format instead of the <Format>[ex.srclink]</Format> and <Format>[ex./srclink]</Format> variables to link to the file.</Text> 1071 <Text id="fw-24b">The resulting format statement is:</Text> 1072 <Format> 1073 <td valign="top">[link][icon][/link]</td><br/> 1074 <td valign="top"><highlight>{If}{[ex.FileFormat] eq 'PDF', <a 1075 href=\"_httpcollection_/index/assoc/[archivedir]/doc.pdf#search=&quot;_cgiargq_&quot;\">[ex.srcicon]</a>,<br/>[ex.srclink][ex.srcicon][ex./srclink]}</highlight></td><br/> 1076 <td valign="top">[highlight]<br/> 1077 {Or}{[dc.Title],[ex.Title],Untitled}<br/> 1078 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td><br/> 1079 </Format> 1080 <Text id="fw-24i">When the PDF icons are clicked in the search results, Acrobat will open the file with the search window open, and the query terms highlighted.</Text> 1044 <Text id="0322">Now we set the <AutoText text="firstvalueonly"/> option for the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> classifier. Switch to the <AutoText key="glidict::CDM.GUI.Classifiers"/> section of the <AutoText key="glidict::GUI.Design"/> panel, select the <AutoText text="AZCompactList"/> for <AutoText key="metadata::dc.Creator"/> metadata in the <AutoText key="glidict::CDM.ClassifierManager.Assigned"/> box and click <AutoText key="glidict::CDM.ClassifierManager.Configure" type="button"/>. Select the <AutoText text="firstvalueonly"/> option.</Text> 1045 <Text id="0322a"><b>Rebuild</b> and <b>preview</b> the collection. Now the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list classifies documents based on the first author appearing in the <AutoText key="metadata::dc.Creator"/> metadata.</Text> 1046 <Text id="0322b">If you set the <AutoText text="metadata"/> field of <AutoText text="AZCompactList"/> to <Format><AutoText key="metadata::dc.Creator" type="plain"/><AutoText text=",ex.Creator" type="plain"/></Format> in the <TutorialRef id="word_pdf_collection"/> exercise, now the <AutoText key="coredm::_Global:labelCreator_" type="italics"/> list will classify based on the first author appearing in either the <AutoText key="metadata::dc.Creator"/> metadata or the <AutoText key="metadata::ex.Creator"/> metadata.</Text> 1081 1047 </NumberedItem> 1082 1048 </Content> … … 1087 1053 </Title> 1088 1054 <SampleFiles folder="Word_and_PDF"/> 1089 <Version initial="2.70" current="2. 71"/>1055 <Version initial="2.70" current="2.80"/> 1090 1056 <Content> 1091 1057 <Text id="ep-2">Greenstone converts PDF files to HTML using third-party software: <AutoText text="pdftohtml.pl" type="italics"/>. This lets users view these documents even if they don't have the PDF software installed. Unfortunately, sometimes the formatting of the resulting HTML files is not so good.</Text> … … 1094 1060 <Text id="ep-3a">In the Librarian Interface, start a new collection called "PDF collection" and base it on <AutoText key="glidict::NewCollectionPrompt.NewCollection"/>.</Text> 1095 1061 <Text id="ep-3b">In the <AutoText key="glidict::GUI.Gather"/> panel, drag just the PDF documents from <Path>sample_files → Word_and_PDF → Documents</Path> into the new collection. Also drag in the PDF documents from <Path>sample_files → Word_and_PDF → difficult_pdf</Path>.</Text> 1096 <Text id="ep-3c">Go to the <AutoText key="glidict::GUI.Create"/> panel and build the collection. Examine the output from the build process. You will notice that one of the documents could not be processed. The following messages are shown: "The file pdf05-notext.pdf was recognised but could not be processed by any plugin.", and " 5 documentswere processed and included in the collection. 1 was rejected".</Text>1062 <Text id="ep-3c">Go to the <AutoText key="glidict::GUI.Create"/> panel and build the collection. Examine the output from the build process. You will notice that one of the documents could not be processed. The following messages are shown: "The file pdf05-notext.pdf was recognised but could not be processed by any plugin.", and "3 were processed and included in the collection. 1 was rejected".</Text> 1097 1063 </NumberedItem> 1098 1064 <NumberedItem> … … 1106 1072 </Comment> 1107 1073 <NumberedItem> 1108 <Text id="0335">Use the <AutoText key="glidict::Menu.File_Options"/> item on the <AutoText key="glidict::Menu.File"/> menu to switch to <AutoText key="glidict::Preferences.Mode.Expert"/> mode and then build the collection again. The <AutoText key="glidict::GUI.Create"/> panel looks different in <AutoText key="glidict::Preferences.Mode.Expert"/> mode because it gives more options: locate the <AutoText key="glidict::CreatePane.Build_Collection" type="button"/> button, near the bottom of the window, and click it. Now a message appears saying that the file could not be processed, and why. Amongst all the output, we get the following message: "Error: PDF contains no extractable text. Could not convert pdf05 notext.pdf to HTML format". pdftohtml.pl cannot convert a PDF file to HTML if the PDF file has no extractable text.</Text>1074 <Text id="0335">Use the <AutoText key="glidict::Menu.File_Options"/> item on the <AutoText key="glidict::Menu.File"/> menu to switch to <AutoText key="glidict::Preferences.Mode.Expert"/> mode and then build the collection again. The <AutoText key="glidict::GUI.Create"/> panel looks different in <AutoText key="glidict::Preferences.Mode.Expert"/> mode because it gives more options: locate the <AutoText key="glidict::CreatePane.Build_Collection" type="button"/> button, near the bottom of the window, and click it. Now a message appears saying that the file could not be processed, and why. Amongst all the output, we get the following message: "Error: PDF contains no extractable text. Could not convert pdf05-notext.pdf to HTML format". pdftohtml.pl cannot convert a PDF file to HTML if the PDF file has no extractable text.</Text> 1109 1075 </NumberedItem> 1110 1076 <NumberedItem> … … 1187 1153 </NumberedItem> 1188 1154 <NumberedItem> 1189 <Text id="ep-30">Edit the <AutoText text="DocumentText"/> format statement. PDF files processed as HTML will not have images to display, so we need to make sure they get text displayed instead. Change <Format>[srcicon]</Format> to <Format>{Or}{[srcicon],[Text]}</Format>.</Text> 1190 </NumberedItem> 1191 <NumberedItem> 1192 <Text id="ep-33">Build and preview the collection. All PDF documents should look relatively nice. Try searching this collection. You will be able to search for the PDFs that were converted to HTML (try e.g. <AutoText text="bibliography" type="quoted"/>), but not the ones that were converted to images (try searching for <AutoText text="banana" type="quoted"/> or <AutoText text="METS" type="quoted"/>).</Text> 1155 <Text id="ep-30">Edit the <AutoText text="DocumentText"/> format statement. PDF files processed as HTML will not have images to display, so we need to make sure they get text displayed instead. Change <Format>[srcicon]</Format> to <Format>{If}{[NoText] eq "1",[srcicon],[Text]}</Format>.</Text> 1156 </NumberedItem> 1157 <NumberedItem> 1158 <Text id="ep-33">Build and preview the collection. All PDF documents should look relatively nice. Try searching this collection. You will be able to search for the PDFs that were converted to HTML (try e.g. <AutoText text="bibliography" type="quoted"/>), but not the ones that were converted to images (try searching for <AutoText text="FAO" type="quoted"/> or <AutoText text="METS" type="quoted"/>).</Text> 1159 </NumberedItem> 1160 <Heading> 1161 <Text id="fw-24">Opening PDF files with query terms highlighted</Text> 1162 </Heading> 1163 <NumberedItem> 1164 <Text id="fw-24a">Next we'll customize the <AutoText text="SearchVList"/> format statement to highlight the query terms in a PDF file when it is opened from the search result list. This requires Acrobat Reader 7.0 version or higher, and currently only works on a Microsoft Windows platform.</Text> 1165 </NumberedItem> 1166 <NumberedItem> 1167 <Text id="fw-24c">The search terms are kept in the macro variable <AutoText text="_cgiargq_"/>, and we append <AutoText text="#search="_cgiargq_""/> to the end of a PDF file link to pass the query terms to the PDF file.</Text> 1168 <Text id="fw-24d"><AutoText text="PDFPlug"/> renames each PDF file as <AutoText text="doc.pdf"/> and saves it in a unique directory for that document, so we use</Text> 1169 <Format>_httpcollection_/index/assoc/[archivedir]/doc.pdf</Format> 1170 <Text id="fw-24e">to refer to the PDF source file. (However, if you used the <AutoText text="-keep_original_filename"/> option to <AutoText text="PDFPlug"/> when building the collection, the original name of the PDF file is kept, and we use</Text> 1171 <Format>_httpcollection_/index/assoc/[archivedir]/[Source]</Format> 1172 <Text id="fw-24f">instead to locate the PDF source file.)</Text> 1173 </NumberedItem> 1174 <NumberedItem> 1175 <Text id="fw-24g">Select <AutoText text="SearchVList"/> from the list of assigned formats. We need to test whether the file is a PDF file before linking to doc.pdf, using <Format>{If}{[ex.FileFormat] eq 'PDF',,}</Format>. For PDF files, we use the above format instead of the <Format>[ex.srclink]</Format> and <Format>[ex./srclink]</Format> variables to link to the file.</Text> 1176 <Text id="fw-24b">The resulting format statement is:</Text> 1177 <Format> 1178 <td valign="top">[link][icon][/link]</td><br/> 1179 <td valign="top"><highlight>{If}{[ex.FileFormat] eq 'PDF', <a 1180 href=\"_httpcollection_/index/assoc/[archivedir]/doc.pdf#search=&quot;_cgiargq_&quot;\">[ex.srcicon]</a>,<br/>[ex.srclink][ex.srcicon][ex./srclink]}</highlight></td><br/> 1181 <td valign="top">[highlight]<br/> 1182 {Or}{[dc.Title],[ex.Title],Untitled}<br/> 1183 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td><br/> 1184 </Format> 1185 <Text id="fw-24i">When the PDF icons are clicked in the search results, Acrobat will open the file with the search window open, and the query terms highlighted.</Text> 1193 1186 </NumberedItem> 1194 1187 </Content> … … 1198 1191 <Text id="ew-a">Enhanced Word document handling</Text> 1199 1192 </Title> 1200 <Version initial="2.70w" current="2. 71"/>1193 <Version initial="2.70w" current="2.80"/> 1201 1194 <Prerequisite id="word_pdf_collection"/> 1202 1195 <Content> … … 1213 1206 </NumberedItem> 1214 1207 <NumberedItem> 1215 <Text id="ew-5"><b>Build</b> the collection. You will notice that the Microsoft Word program is started up for each Word document—the document is saved as HTML from Word itself, to get a better conversion. <b>Preview</b> the collection. In the <AutoText key="coredm::_Global:labelTitle_"/> list, notice that <Path>word03.doc</Path> and <Path>word06.doc</Path> now have a book icon, rather than a page icon. These now appear with hierarchical structure. But these two are the only ones.</Text>1208 <Text id="ew-5"><b>Build</b> the collection. You will notice that the Microsoft Word program is started up for each Word document—the document is saved as HTML from Word itself, to get a better conversion. <b>Preview</b> the collection. In the <AutoText key="coredm::_Global:labelTitle_"/> list, notice that <Path>word03.doc</Path> and <Path>word06.doc</Path> now have a book icon, rather than a page icon. These now appear with hierarchical structure.</Text> 1216 1209 <Text id="ew-6">The default behaviour for <AutoText text="WordPlug"/> with <AutoText text="windows_scripting"/> is to section the document based on <AutoText text="Heading 1" type="quoted"/>, <AutoText text="Heading 2" type="quoted"/>, <AutoText text="Heading 3" type="quoted"/> styles. If you open up the <Path>word03.doc</Path> or <Path>word06.doc</Path> documents in Word, you will see that the sections use these Heading styles.</Text> 1217 1210 <Text id="ew-7">Note, to view style information in Word, you can select <Menu>Format → Styles and Formatting</Menu> from the menu, and a side bar will appear on the right hand side. Click on a section heading and the formatting information will be displayed in this side bar.</Text> … … 1236 1229 <BulletList> 1237 1230 <Bullet> 1238 <Text id="ew-13"><AutoText text=" PaperTitle" type="italics"/>: Title of the paper</Text>1239 </Bullet> 1240 <Bullet> 1241 <Text id="ew-14"><AutoText text=" SammaryHeader" type="italics"/> (probably mistyped): Summary section</Text>1242 </Bullet> 1243 <Bullet> 1244 <Text id="ew-15"><AutoText text=" Chapter Title" type="italics"/>: Level 1section heading</Text>1245 </Bullet> 1246 <Bullet> 1247 <Text id="ew-16"><AutoText text="S ectionHeading" type="italics"/>: Level 2section heading</Text>1248 </Bullet> 1249 <Bullet> 1250 <Text id="ew-17"><AutoText text=" Reference Heading" type="italics"/>: Reference section</Text>1231 <Text id="ew-13"><AutoText text="ManualTitle" type="italics"/>: Title of the manual</Text> 1232 </Bullet> 1233 <Bullet> 1234 <Text id="ew-14"><AutoText text="ChapterTitle" type="italics"/>: Level 1 section heading</Text> 1235 </Bullet> 1236 <Bullet> 1237 <Text id="ew-15"><AutoText text="SectionHeading" type="italics"/>: Level 2 section heading</Text> 1238 </Bullet> 1239 <Bullet> 1240 <Text id="ew-16"><AutoText text="SubsectionHeading" type="italics"/>: Level 3 section heading</Text> 1241 </Bullet> 1242 <Bullet> 1243 <Text id="ew-17"><AutoText text="AppendixTitle" type="italics"/>: Appendix section title</Text> 1251 1244 </Bullet> 1252 1245 </BulletList> … … 1263 1256 </Format> 1264 1257 <Text id="ew-12">These header options define which styles should be considered as title, level 1, level 2 and level 3 styles. </Text> 1265 <Text id="ew-12a"> Set the options as follows (spaces in the Word styles are removed when converting to HTML styles, and these options must match the HTML styles):</Text>1266 <Format> 1267 level1_header:( SammaryHeader|ChapterTitle|ReferenceHeading)<br/>1258 <Text id="ew-12a">Ensure that the <AutoText text="windows_scripting"/> option is checked, and set the options as follows (spaces in the Word styles are removed when converting to HTML styles, and these options must match the HTML styles):</Text> 1259 <Format> 1260 level1_header:(ChapterTitle|AppendixTitle)<br/> 1268 1261 level2_header: SectionHeading<br/> 1269 title_header: PaperTitle 1262 level3_header: SubsectionHeading<br/> 1263 title_header: ManualTitle 1270 1264 </Format> 1271 1265 <Comment> … … 1285 1279 </Heading> 1286 1280 <NumberedItem> 1287 <Text id="ew-21">If you look at <Path>word06.doc</Path>you will see that it now has two tables of contents. One is generated by Greenstone based on the document's styles, the other was already defined in the Word document. WordPlug can be configured to remove predefined tables of contents and tables of figures. The tables must be defined with Word styles in order for this to work.</Text>1288 </NumberedItem> 1289 <NumberedItem> 1290 <Text id="ew-22">To remove the tables of contents and figures from <Path>word06.doc</Path> , switch on the <AutoText text="delete_toc"/> option in <AutoText text="WordPlug"/>. Set the <AutoText text="toc_header"/> option to <Format>(MsoToc1|MsoToc2|MsoToc3|MsoTof)</Format>. In this document, the table of contents and list of figures use these four style names. Click <AutoText key="glidict::General.OK" type="button"/>.</Text>1291 </NumberedItem> 1292 <NumberedItem> 1293 <Text id="ew-24"><b>Build</b> and <b>preview</b> the collection. <Path>word06.doc</Path> should now have only one table of contents.</Text>1281 <Text id="ew-21">If you look at the HTML versions of <Path>word05.doc</Path> and <Path>word06.doc</Path>, you will see that it now has two tables of contents. One is generated by Greenstone based on the document's styles, the other was already defined in the Word document. WordPlug can be configured to remove predefined tables of contents and tables of figures. The tables must be defined with Word styles in order for this to work.</Text> 1282 </NumberedItem> 1283 <NumberedItem> 1284 <Text id="ew-22">To remove the tables of contents and figures from <Path>word06.doc</Path> and the table of contents from <Path>word05.doc</Path>, switch on the <AutoText text="delete_toc"/> option in <AutoText text="WordPlug"/>. Set the <AutoText text="toc_header"/> option to <Format>(MsoToc1|MsoToc2|MsoToc3|MsoTof|TOA)</Format>. In this document, the table of contents and list of figures use these four style names. Click <AutoText key="glidict::General.OK" type="button"/>.</Text> 1285 </NumberedItem> 1286 <NumberedItem> 1287 <Text id="ew-24"><b>Build</b> and <b>preview</b> the collection. Both <Path>word05.doc</Path> and <Path>word06.doc</Path> should now have only one table of contents.</Text> 1294 1288 </NumberedItem> 1295 1289 <NumberedItem> … … 1300 1294 </Heading> 1301 1295 <NumberedItem> 1302 <Text id="ew-26">W ord document properties can be extracted as metadata. By default, only the Title will be extracted. Other properties can be extracted using the <AutoText text="metadata_fields"/> option.</Text>1296 <Text id="ew-26">When the <AutoText text="windows_scripting"/> option is set, word document properties can be extracted as metadata. By default, only the Title will be extracted. Other properties can be extracted using the <AutoText text="metadata_fields"/> option.</Text> 1303 1297 </NumberedItem> 1304 1298 <NumberedItem> … … 1324 1318 <Text id="0403">Exporting a collection to CD-ROM/DVD</Text> 1325 1319 </Title> 1326 <Version initial="2.60" current="2. 71"/>1320 <Version initial="2.60" current="2.80"/> 1327 1321 <Content> 1328 1322 <Comment> … … 1349 1343 </Title> 1350 1344 <SampleFiles folder="tudor"/> 1351 <Version initial="2.60" current="2. 71"/>1345 <Version initial="2.60" current="2.80"/> 1352 1346 <Content> 1347 <Comment> 1348 <Text id="03881">You will need the files in the <Path>sample_files → tudor</Path> folder.</Text> 1349 </Comment> 1353 1350 <NumberedItem> 1354 1351 <Text id="0388">Invoke the Greenstone Librarian Interface (from the Windows <i>Start</i> menu) and start a new collection called <b>tudor</b> (use the <AutoText key="glidict::Menu.File"/> menu), based on the default <AutoText key="glidict::NewCollectionPrompt.NewCollection"/>.</Text> … … 1380 1377 Title,Author,Page_topic,Content 1381 1378 </Format> 1382 <Text id="0393b-1"> Make sure that you have copied this exactly, with no spaces.Click <AutoText key="glidict::General.OK" type="button"/>.</Text>1379 <Text id="0393b-1">Click <AutoText key="glidict::General.OK" type="button"/>.</Text> 1383 1380 </NumberedItem> 1384 1381 <NumberedItem> … … 1419 1416 </Title> 1420 1417 <Prerequisite id="large_html_collection"/> 1421 <Version initial="2.60" current="2. 71"/>1418 <Version initial="2.60" current="2.80"/> 1422 1419 <Content> 1423 1420 <Comment> … … 1532 1529 </Title> 1533 1530 <Prerequisite id="large_html_collection"/> 1534 <Version initial="2.60" current="2. 71"/>1531 <Version initial="2.60" current="2.80"/> 1535 1532 <Content> 1536 1533 <NumberedItem> … … 1540 1537 <td valign=top>[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]} [ex./srclink]</td><br/> 1541 1538 <td valign=top>[highlight]<br/> 1542 {Or}{[d ls.Title],[dc.Title],[ex.Title],Untitled}<br/>1539 {Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}<br/> 1543 1540 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>}</td> 1544 1541 </Format> … … 1609 1606 <td>[link][icon][/link]</td><br/> 1610 1607 <td>{If}{[numleafdocs],<b>Bookshelf title:</b> [ex.Title],<br/> 1611 Title:</b> [ex.Title]}<br/>1608 <b>Title:</b> [ex.Title]}<br/> 1612 1609 </td> 1613 1610 </Format> … … 1626 1623 <Text id="st-1">Section tagging for HTML documents</Text> 1627 1624 </Title> 1628 <Version initial="2.70w" current="2. 71"/>1625 <Version initial="2.70w" current="2.80"/> 1629 1626 <Content> 1630 1627 <NumberedItem> … … 1682 1679 <Text id="0411">Downloading files from the web</Text> 1683 1680 </Title> 1684 <Version initial="2.60" current="2. 71"/>1681 <Version initial="2.60" current="2.80"/> 1685 1682 <Content> 1686 1683 <Comment> … … 1692 1689 <NumberedItem> 1693 1690 <Text id="0414">In a web browser, visit <Link>http://englishhistory.net</Link>, follow the link to <i>Tudor England</i>, and click <<b>Enter</b>>. You should be at the URL</Text> 1694 <Link>http://englishhistory.net/tudor /contents.html</Link>1691 <Link>http://englishhistory.net/tudor.html</Link> 1695 1692 <Text id="0415">This is where we started the downloading process to obtain the files you have been using for the <b>tudor</b> collection. You could do the same thing by copying this URL from the web browser, pasting it into the <AutoText key="glidict::GUI.Download"/> panel, and clicking the <AutoText key="glidict::Mirroring.Download" type="button"/> button. However, several megabytes will be downloaded, which might strain your network resources—or your patience! For a faster exercise we focus on a smaller section of the site. </Text> 1696 1693 </NumberedItem> … … 1699 1696 <Text id="0415b">Enter this URL</Text> 1700 1697 <Link>http://englishhistory.net/tudor/citizens/</Link> 1701 <Text id="0417">into the <AutoText text="url"/> box. There are several other options that govern how the download process proceeds. To see a description of an option, hover the mouse over it and a tooltip will appear. To copy just the <i>citizens</i> section of the website, switch on the <AutoText text="below"/> option by checking its box . If you don't do this (or if you miss out the terminating "/" in the URL), the downloading process will follow links to other areas of the <i>englishhistory.net</i> website and grab those as well.</Text>1698 <Text id="0417">into the <AutoText text="url"/> box. There are several other options that govern how the download process proceeds. To see a description of an option, hover the mouse over it and a tooltip will appear. To copy just the <i>citizens</i> section of the website, switch on the <AutoText text="below"/> option by checking its box and set the <AutoText text="depth"/> option to 1. If you don't do this (or if you miss out the terminating "/" in the URL), the downloading process will follow links to other areas of the <i>englishhistory.net</i> website and grab those as well.</Text> 1702 1699 </NumberedItem> 1703 1700 <NumberedItem> … … 1724 1721 </Title> 1725 1722 <Prerequisite id="downloading_from_internet"/> 1726 <Version initial="2.60" current="2. 71"/>1723 <Version initial="2.60" current="2.80"/> 1727 1724 <Content> 1728 1725 <NumberedItem> 1729 <Text id="0424">Open up your <b> webtudor</b> collection, and in the <AutoText key="glidict::GUI.Gather"/> panel inspect the files you dragged into it. The first folder is <Path>englishhistory.net</Path>, which opens up to reveal <Path>tudor</Path>, and so on. The files represent a complete sweep of the pages (and supporting images) that constitute the <i>Tudor citizens</i> section of the <i>englishhistory.net</i> web site. They were downloaded from the web in a way that preserved the structure of the original site. This allows any page's original URL to be reconstructed from the folder hierarchy.</Text>1726 <Text id="0424">Open up your <b>tudor</b> collection, and in the <AutoText key="glidict::GUI.Gather"/> panel inspect the files you dragged into it. The first folder is <Path>englishhistory.net</Path>, which opens up to reveal <Path>tudor</Path>, and so on. The files represent a complete sweep of the pages (and supporting images) that constitute the <i>Tudor citizens</i> section of the <i>englishhistory.net</i> web site. They were downloaded from the web in a way that preserved the structure of the original site. This allows any page's original URL to be reconstructed from the folder hierarchy.</Text> 1730 1727 </NumberedItem> 1731 1728 <NumberedItem> … … 1758 1755 </Title> 1759 1756 <SampleFiles folder="marc"/> 1760 <Version initial="2.60" current="2. 71"/>1757 <Version initial="2.60" current="2.80"/> 1761 1758 <Content> 1762 1759 <Comment> 1763 <Text id="0520a">This exercise looks at using fielded searching in a collection. Fielded searching is best used for metadata rich collections. Here we use bibliographic data in MARC format. We also "explode" the database, enabling editing of the metadata with the Librarian Interface.</Text> 1764 </Comment> 1765 <NumberedItem> 1766 <Text id="0521">Start a new collection called <b>Beatles Bibliography</b> which will contain a collection of MARC records on the Beatles, from the US Library of Congress. Enter the requested information and base it on <AutoText key="glidict::NewCollectionPrompt.NewCollection"/>.</Text> 1767 </NumberedItem> 1768 <NumberedItem> 1769 <Text id="0522">In the <AutoText key="glidict::GUI.Gather"/> panel, open the <Path>sample_files → marc</Path> folder, drag <Path>locbeatles50.marc</Path> into the right-hand pane and drop it there. A popup window asks whether you want to add <AutoText text="MARCPlug" /> to the collection to process this file. Click <AutoText key="glidict::CDM.PlugInManager.QuickAdd" type="button"/>, because this plugin will be needed to process the MARC records.</Text> 1770 </NumberedItem> 1771 <NumberedItem> 1772 <Text id="0523">In the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, remove the plugins <AutoText text="TextPlug" /> to <AutoText text="NULPlug" /> by selecting each one in the <AutoText key="glidict::CDM.PlugInManager.Assigned"/> list and clicking <AutoText key="glidict::CDM.PlugInManager.Remove" type="button"/> (<AutoText text="ZIPPlug" />, <AutoText text="GAPlug" /> and <AutoText text="MARCPlug" /> remain). It is not strictly necessary to remove these redundant plugins, but it is good practice to include only plugins that are needed, to avoid unwanted (and unexpected) side effects.</Text> 1773 </NumberedItem> 1760 <Text id="0520a">This exercise looks at using fielded searching in a collection. Fielded searching is best used for metadata rich collections. Here we use bibliographic data in MARC format.</Text> 1761 </Comment> 1762 <NumberedItem> 1763 <Text id="0521">Start a new collection called <b>Papers Bibliography</b> which will contain a collection of example MARC records of the working papers published at the <Link url="http://www.cs.waikato.ac.nz">Computer Science Department</Link>, <Link url="http://www.waikato.ac.nz">Waikato University</Link>. Enter the requested information and base it on <AutoText key="glidict::NewCollectionPrompt.NewCollection"/>.</Text> 1764 </NumberedItem> 1765 <NumberedItem> 1766 <Text id="0522">In the <AutoText key="glidict::GUI.Gather"/> panel, open the <Path>sample_files → marc</Path> folder, drag <Path>CMSwp-all.marc</Path> into the right-hand pane and drop it there. A popup window asks whether you want to add <AutoText text="MARCPlug" /> to the collection to process this file. Click <AutoText key="glidict::CDM.PlugInManager.QuickAdd" type="button"/>, because this plugin will be needed to process the MARC records.</Text> 1767 </NumberedItem> 1768 <!-- don't need to remove the plugins --> 1769 <!-- 1770 <NumberedItem> 1771 <Text id="0523">In the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, remove the plugins <AutoText text="TextPlug" /> to <AutoText text="NULPlug" /> by selecting each one in the <AutoText key="glidict::CDM.PlugInManager.Assigned"/> list and clicking <AutoText key="glidict::CDM.PlugInManager.Remove" type="button"/> (<AutoText text="ZIPPlug" />, <AutoText text="GAPlug" />, <AutoText text="MetadataXMLPlug"/> and <AutoText text="MARCPlug" /> remain). It is not strictly necessary to remove these redundant plugins, but it is good practice to include only plugins that are needed, to avoid unwanted (and unexpected) side effects.</Text> 1772 </NumberedItem> 1773 --> 1774 1774 <NumberedItem> 1775 1775 <Text id="0524">Now select <AutoText key="glidict::CDM.GUI.Classifiers"/> within the <AutoText key="glidict::GUI.Design"/> panel and <b>remove</b> the default classifier for <b>Source</b> metadata.</Text> … … 1779 1779 </NumberedItem> 1780 1780 <NumberedItem> 1781 <Text id="0525">Switch to the <AutoText key="glidict::GUI.Create"/> panel, <b>build</b> the collection, and <b>preview</b> it. Browse through the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> and view a record or two. Try searching—for example, find items that include <AutoText text=" rock music"/>.</Text>1781 <Text id="0525">Switch to the <AutoText key="glidict::GUI.Create"/> panel, <b>build</b> the collection, and <b>preview</b> it. Browse through the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> and view a record or two. Try searching—for example, find items that include <AutoText text="graphics"/>.</Text> 1782 1782 </NumberedItem> 1783 1783 <NumberedItem> … … 1794 1794 </Heading> 1795 1795 <NumberedItem> 1796 <Text id="0531a"> Collections built with MGPP (the default indexer) provide the option offielded searching. In the browser, go to the <AutoText key="coredm::_Global:linktextPREFERENCES_" type="italics"/> page. You will notice that there is a <AutoText key="coredm::_preferences:textsearchtype_" /> option which enables you to switch between "normal" and "fielded" search. Change to fielded search now and click on the <AutoText key="coredm::_Global:labelSearch_"/> button. The search form has changed to a fielded form.</Text>1796 <Text id="0531a">Now let's look at fielded searching. In the browser, go to the <AutoText key="coredm::_Global:linktextPREFERENCES_" type="italics"/> page. You will notice that there is a <AutoText key="coredm::_preferences:textsearchtype_" /> option which enables you to switch between "normal" and "fielded" search. Change to fielded search now and click on the <AutoText key="coredm::_Global:labelSearch_"/> button. The search form has changed to a fielded form.</Text> 1797 1797 </NumberedItem> 1798 1798 <NumberedItem> … … 1803 1803 </NumberedItem> 1804 1804 <NumberedItem> 1805 <Text id="0533"><b>Preview</b> the collection again. Notice that the collection's home page no longer includes a query box. (This is because the search form is too big to fit here nicely.) To search, you have to click <AutoText key="coredm::_Global:labelSearch_"/> in the navigation bar. Note that the <AutoText key="coredm::_Global:linktextPREFERENCES_" type="italics"/> page has changed so that the "normal" query style is no longer offered.</Text>1805 <Text id="0533"><b>Preview</b> the collection again. Notice that the collection's home page no longer includes a query box. (This is because the search form is too big to fit here nicely.) To search, you have to click <AutoText key="coredm::_Global:labelSearch_"/> in the navigation bar. Note that the <AutoText key="coredm::_Global:linktextPREFERENCES_" type="italics"/> page has changed so that the "normal" query style is no longer the default value.</Text> 1806 1806 </NumberedItem> 1807 1807 <NumberedItem> … … 1833 1833 </NumberedItem> 1834 1834 <NumberedItem> 1835 <Text id="0533-9">Once exploding has finished, the MARC database file will have been deleted, and a folder created in its place. This folder contains an empty file for each record in the original database. The metadata for these records can be viewed and edited by switching to the <AutoText key="glidict::GUI.Enrich"/> panel.</Text> 1836 </NumberedItem> 1837 <NumberedItem> 1838 <Text id="0533-10">Because the MARC file is no longer present, and the collection contains empty (.nul) files, we need to change the list of plugins. In the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, remove <AutoText text="MARCPlug"/> and add <AutoText text="NULPlug"/> (use the default configuration).</Text> 1839 </NumberedItem> 1840 <NumberedItem> 1841 <Text id="0533-11"><b>Rebuild</b> and <b>preview</b> the collection. You will notice that the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> classifier displays the filename not the record title, the <AutoText key="coredm::_Global:labelSubject_" type="italics"/> classifier is empty, searching no longer returns any results, and the document display is useless.</Text> 1835 <Text id="0533-9">Once exploding has finished, the MARC database file will have been deleted, and three folders created in its place. These folders contain an empty file for each record in the original database. The metadata for these records can be viewed and edited by switching to the <AutoText key="glidict::GUI.Enrich"/> panel.</Text> 1836 </NumberedItem> 1837 <NumberedItem> 1838 <Text id="0533-10">Because the MARC file is no longer present, and the collection contains empty (.nul) files, we need to change the list of plugins. In the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel, remove <AutoText text="MARCPlug"/>.</Text> 1839 </NumberedItem> 1840 <NumberedItem> 1841 <Text id="0533-11"><b>Rebuild</b> and <b>preview</b> the collection. You will notice that the <AutoText key="coredm::_Global:labelSubject_" type="italics"/> classifier is empty, searching no longer returns any results, and the document display is useless.</Text> 1842 <Text id="0533-11b">Although the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> classifier was built on <AutoText key="metadata::ex.Title"/>, it still displays the correct titles, but in the <AutoText key="glidict::GUI.Enrich"/> panel you can see the <AutoText key="metadata::ex.Title"/> metadata are actually the filenames rather than titles of the MARC records. This is because the default <AutoText text="VList"/> format uses the <AutoText key="metadata::exp.Title"/> metadata. In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select <AutoText text="VList"/> in the list of assigned format statements. The resulting format statement looks like:</Text> 1843 <Format> 1844 <td valign="top">[link][icon][/link]</td><br/> 1845 <td valign="top">[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]}[ex./srclink]</td><br/> 1846 <td valign="top">[highlight]<br/> 1847 {Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}<br/> 1848 [/highlight]{If}{[ex.Source],<br><i>([ex.Source])</i>} 1849 </Format> 1850 <Text id="0533-11c">Since there is no <AutoText key="metadata::dc.Title"/> metadata and <AutoText key="metadata::exp.Title"/> comes before <AutoText key="metadata::ex.Title"/>, the expoded titles will be displayed.</Text> 1842 1851 </NumberedItem> 1843 1852 <Heading> 1844 1853 <Text id="0533-11a">Reformatting the collection to use the exploded metadata</Text> 1845 1854 </Heading> 1846 <Text id="0533-12">The collection previously used extracted (ex.) metadata, but now it uses exploded (exp.) metadata. The classifiersand search indexes were built on ex metadata, which is why they no longer work properly.</Text>1855 <Text id="0533-12">The collection previously used extracted (ex.) metadata, but now it uses exploded (exp.) metadata. The <AutoText key="coredm::_Global:labelSubject_" type="italics"/> classifier and search indexes were built on ex metadata, which is why they no longer work properly.</Text> 1847 1856 <Text id="0533-12a">There is also no longer any text in the documents. Previously, MARCPlug stored the raw record as the "text" of each record. Now that the metadata is in the Librarian Interface, there is no longer the concept of raw record, and so there is no text.</Text> 1848 1857 <Text id="0533-12b">We need to modify the collection design to take note of these changes.</Text> … … 1860 1869 </NumberedItem> 1861 1870 <NumberedItem> 1862 <Text id="0533-15">In the <AutoText key="glidict::CDM.GUI.Classifiers"/> section, change the <AutoText key="metadata::ex.Title"/> <AutoText text="AZList"/> to use <AutoText key="metadata::exp.Title"/> metadata. Double click the <AutoText key="metadata::ex.Title"/> <AutoText text="AZList"/> in the <AutoText key="glidict::CDM.ClassifierManager.Assigned"/> list, and change the <AutoText text="metadata"/> option to use <AutoText key="metadata::exp.Title"/>. Click <AutoText key="glidict::General.OK" type="button"/>. Do the same thing for the Subject <AutoText text="AZCompactList"/>, changing <AutoText key="metadata::ex.Subject"/> to <AutoText key="metadata::exp.Subject"/>.</Text> 1871 <Text id="0533-15">To explicitly use the <AutoText key="metadata::exp.Title"/> metadata, in the <AutoText key="glidict::CDM.GUI.Classifiers"/> section, change the <AutoText key="metadata::ex.Title"/> <AutoText text="AZList"/> to use <AutoText key="metadata::exp.Title"/> metadata. Double click the <AutoText key="metadata::ex.Title"/> <AutoText text="AZList"/> in the <AutoText key="glidict::CDM.ClassifierManager.Assigned"/> list, and change the <AutoText text="metadata"/> option to use <AutoText key="metadata::exp.Title"/>. Click <AutoText key="glidict::General.OK" type="button"/>. Do the same thing for the Subject <AutoText text="AZCompactList"/>, changing <AutoText key="metadata::ex.Subject"/> to <AutoText key="metadata::exp.Subject"/>.</Text> 1872 </NumberedItem> 1873 <NumberedItem> 1874 <Text id="0533-23"><b>Rebuild</b> and <b>preview</b> the collection. The classifiers should be back to normal and searching should now work.</Text> 1863 1875 </NumberedItem> 1864 1876 <NumberedItem> … … 1866 1878 <BulletList> 1867 1879 <Bullet> 1868 <Text id="0533-16a">There is no d ls or dc metadata for this collection, so replace <Format>{Or}{[dls.Title],[dc.Title],[ex.Title],Untitled}</Format> with <Format>{Or}{[exp.Title],[ex.Title],Untitled}</Format>.</Text>1880 <Text id="0533-16a">There is no dc metadata for this collection, so replace <Format>{Or}{[dc.Title],[exp.Title],[ex.Title],Untitled}</Format> with <Format>{Or}{[exp.Title],[ex.Title],Untitled}</Format>.</Text> 1869 1881 </Bullet> 1870 1882 <Bullet> … … 1898 1910 <NumberedItem> 1899 1911 <Text id="0533-22">The <AutoText key="coredm::_document:textDETACH_" type="italics"/> and <AutoText key="coredm::_document:textNOHIGHLIGHT_" type="italics"/> buttons are not very useful for this collection, so lets get rid of them. Edit the <AutoText text="DocumentButtons"/> format statement to make it empty.</Text> 1900 </NumberedItem>1901 <NumberedItem>1902 <Text id="0533-23"><b>Rebuild</b> and <b>preview</b> the collection. The classifiers should be back to normal, searching should now work, and there should be a nice record display.</Text>1903 1912 </NumberedItem> 1904 1913 </Content> … … 1909 1918 </Title> 1910 1919 <SampleFiles folder="isis"/> 1911 <Version initial="2.70w" current="2. 71"/>1920 <Version initial="2.70w" current="2.80"/> 1912 1921 <Content> 1913 1922 <Comment> … … 1915 1924 </Comment> 1916 1925 <NumberedItem> 1917 <Text id="is-3">Start a new collection called <b>ISIS Collection</b> .</Text>1926 <Text id="is-3">Start a new collection called <b>ISIS Collection</b> (base it on <b>New Collection</b>).</Text> 1918 1927 </NumberedItem> 1919 1928 <NumberedItem> … … 1971 1980 </Title> 1972 1981 <SampleFiles folder="custom"/> 1973 <Version initial="2.70" current="2. 71"/>1982 <Version initial="2.70" current="2.80"/> 1974 1983 <Content> 1975 1984 <Text id="mf-2">The appearance of all pages produced by Greenstone is governed by macro files, which reside in the folder <Path>Greenstone → macros</Path>, images, and CSS stylesheets, both of which reside in <Path>Greenstone → images</Path>. </Text> 1976 1985 <Text id="mf-3">A macro takes the form <Format>_macroname_ {macro value}</Format>. Macro names start and end with underscores (_), and the macro value is enclosed in curly brackets ({}). Macro values can be text or HTML, and can include other macros.</Text> 1977 <Text id="mf-4">Macros are grouped into packages, and different packages control the appearance of different pages. For example, the <AutoText text="home"/>, <AutoText text="help"/>, <AutoText text="preferences"/>, <AutoText text="query"/>, <AutoText text="document"/> packages control the home, help, preferences, query, and document pages, respectively. Some macro files contain macros for just one package, for example, <Path>home.dm</Path>, <Path>query.dm</Path>, <Path>document.dm</Path>, while others contain macros for many packages. <Path>base.dm</Path> contains macros used globally, <Path>style.dm</Path> controls the common style of each page, <Path>english.dm</Path>, <Path>french.dm</Path> and other language files contain the text fragments for the entire interface, in that specificlanguage. </Text>1986 <Text id="mf-4">Macros are grouped into packages, and different packages control the appearance of different pages. For example, the <AutoText text="home"/>, <AutoText text="help"/>, <AutoText text="preferences"/>, <AutoText text="query"/>, <AutoText text="document"/> packages control the home, help, preferences, query, and document pages, respectively. Some macro files contain macros for just one package, for example, <Path>home.dm</Path>, <Path>query.dm</Path>, <Path>document.dm</Path>, while others contain macros for many packages. <Path>base.dm</Path> contains macros used globally, <Path>style.dm</Path> controls the common style of each page, <Path>english.dm</Path>, <Path>french.dm</Path> and other language files contain the text fragments for the entire interface, in that language. </Text> 1978 1987 <Text id="mf-5">The output of the library program is a page of HTML which is viewed in a web browser. CSS (Cascading Style Sheets) are often used alongside HTML pages to control the formatting, such as layout, colour, font etc. The default Greenstone stylesheet is <Path>Greenstone → images → style.css</Path>.</Text> 1979 1988 <Text id="mf-6">In this exercise, we customize the macros, images and stylesheets to change the appearance of our library.</Text> 1980 1989 <Heading> 1981 <Text id="mf-7">Changing the background and header images</Text>1982 </Heading>1983 <NumberedItem>1984 <Text id="mf-8">Three new images for this exercise can be found in <Path>sample_files → custom</Path>. Copy <Path>chalk-blue.gif</Path>, <Path>gsdlhead-blue.gif</Path> and <Path>divb-blue.gif</Path> from the <Path>custom</Path> folder into the <Path>Greenstone → images</Path> folder.</Text>1985 </NumberedItem>1986 <NumberedItem>1987 <Text id="mf-9">Open the file <Path>Greenstone → macros → home.dm</Path> in a text editor, e.g. WordPad. Find each occurrence of <Format>gsdlhead.gif</Format> in this file (there are two) and replace with <Format>gsdlhead-blue.gif</Format>. (If you are using WordPad, you can use <Menu>Edit → Find</Menu> to search for the text.)</Text>1988 <Text id="mf-10">Save <Path>home.dm</Path> and close the file.</Text>1989 </NumberedItem>1990 <NumberedItem>1991 <Text id="mf-11">Open the file <Path>Greenstone → macros → style.dm</Path> with the same program. Locate the following part of the file (this is part of the <Format>_cssheader_</Format> macro):</Text>1992 <Format>1993 <style type="text/css"><br/>1994 body.bgimage \{ background-image: url("_httpimg_/chalk.gif"); \}<br/>1995 </Format>1996 <Text id="mf-12">Use copy and paste on the <Format>body.bgimage</Format> line to make it look like this: </Text>1997 <Format>1998 <style type="text/css"><br/>1999 /*body.bgimage \{ background-image: url("_httpimg_/chalk.gif"); \}*/<br/>2000 body.bgimage \{ background-image: url("_httpimg_/chalk-blue.gif"); \}<br/>2001 </Format>2002 <Text id="mf-13">/*...*/ around a line signals a comment, and this style element will be ignored. We use this to "comment out" the original line and replace it with a modified line. This way it is easy to revert back to the original if necessary. Here we are changing the background image for the <Format>bgimage</Format> section of the <Format>body</Format> of the page to <Format>chalk-blue.gif</Format>.</Text>2003 <Text id="mf-14">Save <Path>style.dm</Path> and close the file.</Text>2004 </NumberedItem>2005 <NumberedItem>2006 <Text id="mf-15">Preview the home page in a web browser. (On Windows, restart the Greenstone library server.) The page header and background should now use the new graphics, and be blue.</Text>2007 <Comment>2008 <Text id="mf-15a">The final part of this exercise looks at how we determined which images needed replacing, and which macro files should be edited.</Text>2009 </Comment>2010 </NumberedItem>2011 <Heading>2012 <Text id="mf-16">Changing the colour of the navigation bar, page title and page text</Text>2013 </Heading>2014 <Text id="mf-17">Now that the background image is a nice blue colour, lets format the page so that some other parts are blue too. Preview the collection after each change to make sure that it has worked properly. On Windows, macro file changes require a restart of the Greenstone library server. Stylesheet changes may require a force reload in the web browser.</Text>2015 <NumberedItem>2016 <Text id="mf-18">First, we'll change the colour of the navigation bar and green divider bars. These use an image as a background, specified in the same macro as the page background.</Text>2017 <Text id="mf-19">Open <Path>Greenstone → macros → style.dm</Path> in a text editor, and find the <Format>_cssheader_</Format> macro that you modified previously. Change the <Format>div.navbar</Format> and <Format>div.divbar</Format> parts to use <Format>divb-blue.gif</Format> instead of <Format>bg_green.png</Format>:</Text>2018 <Format>2019 /*div.navbar \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/>2020 div.navbar \{ background-image: url("_httpimg_/divb-blue.gif"); \}<br/>2021 /*div.divbar \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/>2022 div.divbar \{ background-image: url("_httpimg_/divb-blue.gif"); \}<br/>2023 </Format>2024 </NumberedItem>2025 <NumberedItem>2026 <Text id="mf-20">The selected item on the navigation bar uses the same background, so change that too:</Text>2027 <Format>2028 /*a.navlink_sel \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/>2029 a.navlink_sel \{ background-image: url("_httpimg_/divb-blue.gif"); \}2030 </Format>2031 </NumberedItem>2032 <NumberedItem>2033 <Text id="mf-21">Next, we get rid of the background green image on the page and collection titles. Comment out the <Format>p.bannertitle</Format> and <Format>p.collectiontitle</Format> parts:</Text>2034 <Format>2035 /*p.bannertitle \{background-image: url("_httpimg_/banner_bg.png"); \}*/<br/>2036 /*p.collectiontitle \{background-image: url("_httpimg_/banner_bg.png"); \}*/2037 </Format>2038 </NumberedItem>2039 <Text id="mf-22">The above style definitions were included in the macro file so that image paths could be dynamically generated. The majority of the style definitions reside in an external style file, <Path>Greenstone → images → style.css</Path>, and most style changes involve modifying that file.</Text>2040 <NumberedItem>2041 <Text id="mf-23">Open <Path>Greenstone → images → style.css</Path> in a text editor. Make the following modifications. You might want to preview after each one to see the effect.</Text>2042 <Text id="mf-24">Change some of the colours:</Text>2043 <BulletList>2044 <Bullet>2045 <Text id="mf-27">Find the <Format>body</Format> style instructions:</Text>2046 <Format>2047 body {<br/>2048 background: #ffffff;<br/>2049 color: #000000;<br/>2050 }2051 </Format>2052 <Text id="mf-27a">Set <Format>color</Format> to <Format>teal</Format>.</Text>2053 </Bullet>2054 <Bullet>2055 <Text id="mf-25">For <Format>a.collectiontitle</Format>, set <Format>color</Format> to <Format>blue</Format>.</Text>2056 </Bullet>2057 <Bullet>2058 <Text id="mf-26">For <Format>p.collectiontitle</Format>, add <Format>color: blue;</Format></Text>2059 </Bullet>2060 </BulletList>2061 </NumberedItem>2062 <NumberedItem>2063 <Text id="mf-28">For fun, lets switch the positions of the home, help and preferences buttons and the collection name or image.</Text>2064 <BulletList>2065 <Bullet>2066 <Text id="mf-29">For <Format>div.pageinfo</Format>, set both <Format>float</Format> and <Format>text-align</Format> to <Format>left</Format>.</Text>2067 </Bullet>2068 <Bullet>2069 <Text id="mf-30">For <Format>div.collectimage</Format>, set <Format>float</Format> and <Format>text-align</Format> to <Format>right</Format>.</Text>2070 </Bullet>2071 </BulletList>2072 <Text id="mf-31">The look of your library should now be substantially different.</Text>2073 </NumberedItem>2074 <Heading>2075 <Text id="mf-32">Adding a footer</Text>2076 </Heading>2077 <NumberedItem>2078 <Text id="mf-33">Next we add a footer to each page. <Path>Greenstone → macros → style.dm</Path> defines a header and footer for each page, and macro files for the different pages define the page content. Open the file <Path>Greenstone → macros → style.dm</Path> in a text editor.</Text>2079 </NumberedItem>2080 <NumberedItem>2081 <Text id="mf-34">Locate the <Format>_footer_</Format> macro:</Text>2082 <Format>2083 _footer_ {<br/>2084 <!-- page footer (\_style:footer\_) --><br/>2085 _pagefooterextra__endspacer__htmlfooter_<br/>2086 }2087 </Format>2088 <Text id="mf-35">After <Format>_pagefooterextra_</Format> add some text or HTML. For example <Format><center><small>Copyright 2006 My Awesome Digital Library</small></center></Format>. The resulting macro will look something like:</Text>2089 <Format>2090 _footer_ {<br/>2091 <!-- page footer (\_style:footer\_) --><br/>2092 _pagefooterextra_2093 <center><small>Copyright 2006 My Awesome Digital Library</small></center>2094 _endspacer__htmlfooter_<br/>2095 }2096 </Format>2097 <Comment>2098 <Text id="mf-36">The <Format><center></Format> and <Format><small></Format> HTML tags center the text, and make it a smaller size than the rest of the page.</Text>2099 </Comment>2100 <Text id="mf-37">Save <Path>style.dm</Path> and close the file.</Text>2101 </NumberedItem>2102 <NumberedItem>2103 <Text id="mf-38">Preview the changes in a web browser. (On Windows, restart the Greenstone library server.) Each page should now have the new text at the bottom.</Text>2104 </NumberedItem>2105 <NumberedItem>2106 <Text id="mf-39">Adding text into the main <Format>_footer_</Format> macro adds it to all pages. To add a footer just to a particular page, use <Format>_pagefooterextra_</Format> in the appropriate macro file. For example, lets add some more text to the footer, this time just on the home page.</Text>2107 <Text id="mf-40">Open the file <Path>Greenstone → macros → home.dm</Path> in a text editor. After the line <Format>package home</Format>, add the following text:</Text>2108 <Format>2109 _pagefooterextra_ {Collections generated by Me.}2110 </Format>2111 <Text id="mf-41">Save <Path>home.dm</Path> and close the file.</Text>2112 <Text id="mf-42">Preview the home page in a web browser. (On Windows, restart the Greenstone library server.) The home page should now display the new text, while the other pages won't.</Text>2113 </NumberedItem>2114 <Heading>2115 <Text id="mf-43">Make your own Greenstone home page</Text>2116 </Heading>2117 <Text id="mf-44">You can make radical changes to a page by changing the macro file completely. For example, here we use a predefined alternative to the home page.</Text>2118 <NumberedItem>2119 <Text id="mf-45">Open the file <Path>Greenstone → etc → main.cfg</Path> in a text editor. Locate the <AutoText text="macrofiles" type="italics"/> list:</Text>2120 <Format>2121 # The list of display macro files used by this receptionist<br/>2122 macrofiles tip.dm style.dm base.dm query.dm help.dm pref.dm about.dm \<br/>2123 document.dm browse.dm status.dm authen.dm users.dm html.dm \<br/>2124 extlink.dm gsdl.dm extra.dm home.dm collect.dm docs.dm \<br/>2125 bsummary.dm gti.dm gli.dm nav_css.dm usability.dm \<br/>2126 ...<br/>2127 </Format>2128 <Text id="mf-46">Change the text <Format>home.dm</Format> to <Format>yourhome.dm</Format>. Save and close the file.</Text>2129 </NumberedItem>2130 <NumberedItem>2131 <Text id="mf-47">Preview the newly structured home page in a web browser. (On Windows, restart the Greenstone library server.) </Text>2132 </NumberedItem>2133 <NumberedItem>2134 <Text id="mf-48">Reverse this last change by changing <Format>yourhome.dm</Format> back to <Format>home.dm</Format> in the file <Path>Greenstone → etc → main.cfg</Path>. You may also like to reverse the other changes you have made.</Text>2135 </NumberedItem>2136 <Heading>2137 1990 <Text id="mf-49">Collection specific customisation</Text> 2138 1991 </Heading> 2139 <Text id="mf-50">Macros can also be used to customize single collections. They should be added to a file called <Path>extra.dm</Path> in the <Path>macros</Path> directory of a collection. This part of the exercise can be done using the Librarian Interface.</Text>2140 <Text id="mf-51">We use the Word and PDF collection (from exercise <TutorialRef id="word_pdf_collection"/>) as the example for this exercise, but it can be done with any collection. Open up this collection ( reports) in the Librarian Interface.</Text>2141 <NumberedItem> 2142 <Text id="mf-51a">Go to the <AutoText key="glidict::GUI.Format"/> panel, and select <AutoText key="glidict::CDM.GUI.Macros"/> from the left hand list. This section allows you to edit the collection's extra.dmmacro file.</Text>2143 </NumberedItem> 2144 <NumberedItem> 2145 <Text id="mf-53">First, we change the title of the <AutoText key="coredm::_about:textabcol_"/> section of the about page. Add the following text in the edit box :</Text>1992 <Text id="mf-50">Macros can be used to customize single collections by adding them to a file called <Path>extra.dm</Path> in the <Path>macros</Path> directory of a collection.</Text> 1993 <Text id="mf-51">We use the Word and PDF collection (from exercise <TutorialRef id="word_pdf_collection"/>) as the example for this exercise, but it can be done with any collection. Open up this collection (<b>reports</b>) in the Librarian Interface.</Text> 1994 <NumberedItem> 1995 <Text id="mf-51a">Go to the <AutoText key="glidict::GUI.Format"/> panel, and select <AutoText key="glidict::CDM.GUI.Macros"/> from the left hand list. This section allows you to edit the collection's <i>extra.dm</i> macro file.</Text> 1996 </NumberedItem> 1997 <NumberedItem> 1998 <Text id="mf-53">First, we change the title of the <AutoText key="coredm::_about:textabcol_"/> section of the about page. Add the following text in the edit box (which can be copied from the file <Path>about_tweak.txt</Path> in the <Path>sample_files → custom</Path> folder):</Text> 2146 1999 <Format> 2147 2000 package about<br/> … … 2154 2007 } 2155 2008 </Format> 2156 <Text id="mf-55">Preview the collection . (On Windows, restart the Greenstone library server.) The aboutpage will have a new title underneath the search form.</Text>2157 </NumberedItem> 2158 <NumberedItem> 2159 <Text id="mf- 56">Next we'll do some style customisations for this collection. Add the following text:</Text>2009 <Text id="mf-55">Preview the collection by pressing the <AutoText key="glidict::CreatePane.Preview_Collection" type="button"/> button. The <i>About</i> page will have a new title underneath the search form.</Text> 2010 </NumberedItem> 2011 <NumberedItem> 2012 <Text id="mf-33">Next we add a footer to each page. Add the <Format>_footer_</Format> macro to the end of the edit box (which can be copied from the file <Path>footer_tweak.txt</Path> in the <Path>sample_files → custom</Path> folder):</Text> 2160 2013 <Format> 2161 2014 package Style<br/> 2162 2015 <br/> 2016 _footer_ {<br/> 2017 _pagefooterextra_ 2018 <center><small>Copyright 2006 My Awesome Digital Library</small></center> 2019 _endspacer__htmlfooter_<br/> 2020 } 2021 </Format> 2022 <Comment> 2023 <Text id="mf-36">The <Format><center></Format> and <Format><small></Format> HTML tags center the text, and make it a smaller size than the rest of the page.</Text> 2024 </Comment> 2025 </NumberedItem> 2026 <NumberedItem> 2027 <Text id="mf-38">Preview the changes in a web browser. Each page should now have the new text at the bottom.</Text> 2028 </NumberedItem> 2029 <NumberedItem> 2030 <Text id="mf-39">Putting text in the main <Format>_footer_</Format> macro adds it to all pages of this collection. To add a footer just to a particular page, use <Format>_pagefooterextra_</Format> in the appropriate package. For example, lets add some more text to the footer, this time just on the <i>About</i> page.</Text> 2031 <Text id="mf-40">Add the following text immediately after the line 2032 <Format>package about</Format> :</Text> 2033 <Format> 2034 _pagefooterextra_ {Collection generated by Me.} 2035 </Format> 2036 <Text id="mf-42">Preview the <i>About</i> page in a web browser. The <i>About</i> page should now display the new text, while the other pages won't.</Text> 2037 </NumberedItem> 2038 <NumberedItem> 2039 <Text id="mf-56">Next we'll do some style customisations. Add the following text below the <Format>_footer_</Format> macro (which can be copied from the file <Path>red_tweak.txt</Path> in the <Path>sample_files → custom</Path> folder)</Text> 2040 <Format> 2163 2041 _collectionspecificstyle_ {<br/> 2164 2042 <style type="text/css"><br/> … … 2174 2052 } 2175 2053 </Format> 2176 <Text id="mf-57">Preview the collection. (On Windows, restart the Greenstone library server.) The reports collection will now have a pink background, and the navigation bar and divider bars will be red. These changes will only affect this collection.</Text> 2054 <Text id="mf-56a">/*...*/ around a line signals a comment, and this style element will be ignored.</Text> 2055 <Text id="mf-57">Preview the collection. The <b>reports</b> collection will now have a pink background, and the navigation bar and divider bars will be red. These changes will only affect this collection.</Text> 2177 2056 </NumberedItem> 2178 2057 <Text id="mf-58">Any macros from the general macro files can be copied into a collection's <Path>extra.dm</Path> file and modified. Remember to include the package declaration to make sure that the macros get applied to the correct page(s).</Text> 2179 2058 <Text id="mf-59">The style modifications made above were minor. The collection still uses the majority of the standard style file. The style declarations in the <Format>_collectionspecificstyle_</Format> macro get appended to the default ones. To completely change the appearance of a collection, we can use a new style sheet altogether.</Text> 2180 2059 <NumberedItem> 2181 <Text id="mf-59a">Add the following t o <Path>extra.dm</Path>after the last modifications:</Text>2060 <Text id="mf-59a">Add the following text (which can be copied from the file <Path>css_tweak.txt</Path> in the <Path>sample_files → custom</Path> folder) after the last modifications:</Text> 2182 2061 <Format> 2183 2062 _cssheader_ {<br/> … … 2190 2069 </NumberedItem> 2191 2070 <Heading> 2071 <Text id="mf-73">Changing the colour of the page title and page text</Text> 2072 </Heading> 2073 <Text id="mf-17">In the previous exercises we changed a single collection. Now we change all the pages in our Greenstone installation by modifying style and macro files outside the Librarian Interface. First, we format the page so that some other parts are blue. Preview any collection after each change to make sure that it has worked properly. On Windows, macro file changes require a restart of the Greenstone local library server. Stylesheet changes may require a forced reload in the web browser.</Text> 2074 <!-- 2075 <NumberedItem> 2076 <Text id="mf-18">First, we'll change the colour of the navigation bar and green divider bars. These use an image as a background, specified in the same macro as the page background.</Text> 2077 <Text id="mf-19">Open <Path>Greenstone → macros → style.dm</Path> in a text editor, and find the <Format>_cssheader_</Format> macro that you modified previously. Change the <Format>div.navbar</Format> and <Format>div.divbar</Format> parts to use <Format>divb-blue.gif</Format> instead of <Format>bg_green.png</Format>:</Text> 2078 <Format> 2079 /*div.navbar \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/> 2080 div.navbar \{ background-image: url("_httpimg_/divb-blue.gif"); \}<br/> 2081 /*div.divbar \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/> 2082 div.divbar \{ background-image: url("_httpimg_/divb-blue.gif"); \}<br/> 2083 </Format> 2084 <Text id="mf-19a">Preview the collection, now the navigation bar and the green divider change to a blue background. Note that when you select a classifier, the background of the selected item is still green.</Text> 2085 </NumberedItem> 2086 <NumberedItem> 2087 <Text id="mf-20">The selected item on the navigation bar uses the same background, so change that too:</Text> 2088 <Format> 2089 /*a.navlink_sel \{ background-image: url("_httpimg_/bg_green.png"); \}*/<br/> 2090 a.navlink_sel \{ background-image: url("_httpimg_/divb-blue.gif"); \} 2091 </Format> 2092 <Text id="mf-20a">Preview the collection, now the selected classifier is also in a blue background.</Text> 2093 </NumberedItem> 2094 <NumberedItem> 2095 <Text id="mf-21">Next, we get rid of the background green image on the page and collection titles. Comment out the 2096 <Format>p.bannertitle</Format> and <Format>p.collectiontitle</Format> 2097 parts.(If a collection title image is used, you won't see the change of the background on the collection titles.)</Text> 2098 <Format> 2099 /*p.bannertitle \{background-image: url("_httpimg_/banner_bg.png"); \}*/<br/> 2100 /*p.collectiontitle \{background-image: url("_httpimg_/banner_bg.png"); \}*/ 2101 </Format> 2102 <Text id="mf-21a">Preview the collection, the small green background on the collection title image and the page title image is gone.</Text> 2103 </NumberedItem> 2104 <Text id="mf-22">The above style definitions were included in the macro file so that image paths could be dynamically generated. </Text> 2105 --> 2106 <NumberedItem> 2107 <Text id="mf-23">The majority of the style definitions reside in an external style file, <Path>Greenstone → images → style.css</Path>, and most style changes involve modifying that file. Open <Path>Greenstone → images → style.css</Path> in a text editor, e.g. WordPad (and save a .backup copy). Make the following modifications. You might want to preview after each one to see the effect.</Text> 2108 <Text id="mf-24">Change some of the colours:</Text> 2109 <BulletList> 2110 <Bullet> 2111 <Text id="mf-27">Find the <Format>body</Format> style instructions:</Text> 2112 <Format> 2113 body {<br/> 2114 background: #ffffff;<br/> 2115 } 2116 </Format> 2117 <Text id="mf-27a">Add <Format>color: teal;</Format></Text> 2118 </Bullet> 2119 <Bullet> 2120 <Text id="mf-25">For <Format>a.collectiontitle</Format>, set <Format>color</Format> to <Format>blue</Format>.</Text> 2121 </Bullet> 2122 <Bullet> 2123 <Text id="mf-26">For <Format>p.collectiontitle</Format>, add <Format>color: blue;</Format></Text> 2124 </Bullet> 2125 </BulletList> 2126 <Text id="mf-27b">Preview the collection. Now text in the page body is a light green color (teal), and the font of the collection title has changed from black to blue.</Text> 2127 </NumberedItem> 2128 <comment>(If a collection title image is used, you won't see the change on the collection title.)</comment> 2129 <NumberedItem> 2130 <Text id="mf-28">Lets switch the positions of the HOME, HELP and PREFERENCES buttons and the collection name or image.</Text> 2131 <BulletList> 2132 <Bullet> 2133 <Text id="mf-29">For <Format>div.pageinfo</Format>, set both <Format>float</Format> and <Format>text-align</Format> to <Format>left</Format>.</Text> 2134 </Bullet> 2135 <Bullet> 2136 <Text id="mf-30">For <Format>div.collectimage</Format>, set <Format>float</Format> and <Format>text-align</Format> to <Format>right</Format>.</Text> 2137 </Bullet> 2138 </BulletList> 2139 <Text id="mf-31">The look of your library should now be substantially different. The HELP, HOME and PREFERENCES buttons are in the left upper corner whereas the collection title is switched to the right of the page.</Text> 2140 </NumberedItem> 2141 <NumberedItem> 2142 <Text id="mf-8">Now we will customize the default Greenstone header image and the background image. Two new images for this exercise can be found in <Path>sample_files → custom</Path>. Copy <Path>newbgimg.gif</Path>, <Path>newheadimg.gif</Path> from the <Path>custom</Path> folder into the <Path>Greenstone → images</Path> folder.</Text> 2143 </NumberedItem> 2144 <NumberedItem> 2145 <Text id="mf-9">Open the file <Path>Greenstone → macros → home.dm</Path> in a text editor. Find each occurrence of <Format>gsdlhead.gif</Format> in this file (there are two) and replace with <Format>newheadimg.gif</Format>. (If you are using WordPad, you can use <Menu>Edit → Find</Menu> to search for the text.)</Text> 2146 <Text id="mf-10">Save <Path>home.dm</Path> and close the file.</Text> 2147 </NumberedItem> 2148 <NumberedItem> 2149 <Text id="mf-11">Open the file <Path>Greenstone → macros → style.dm</Path> with the text editor. Locate the following part of the file (this is part of the <Format>_cssheader_</Format> macro):</Text> 2150 <Format> 2151 <style type="text/css"><br/> 2152 body.bgimage \{ background-image: url("_httpimg_/chalk.gif"); \}<br/> 2153 </Format> 2154 <Text id="mf-12">Use copy and paste on the <Format>body.bgimage</Format> line to make it look like this: </Text> 2155 <Format> 2156 <style type="text/css"><br/> 2157 /*body.bgimage \{ background-image: url("_httpimg_/chalk.gif"); \}*/<br/> 2158 body.bgimage \{ background-image: url("_httpimg_/newbgimg.gif"); \}<br/> 2159 </Format> 2160 <Text id="mf-13">Here we are changing the background image for the <Format>bgimage</Format> section of the <Format>body</Format> of the page to <Format>newbgimg.gif</Format>.</Text> 2161 <Text id="mf-14">Save <Path>style.dm</Path> and close the file.</Text> 2162 </NumberedItem> 2163 <NumberedItem> 2164 <Text id="mf-15">Preview the home page in a web browser. (On Windows, restart the Greenstone library server.) The header and background of every page of each collection should now use the new graphics.</Text> 2165 </NumberedItem> 2166 <Heading> 2167 <Text id="mf-43">Make your own Greenstone home page</Text> 2168 </Heading> 2169 <Text id="mf-44">You can make radical change to a page by changing the macro file completely. For example, here we use a alternative to the home page which we have prepared for you in advance and included in your Greenstone installation.</Text> 2170 <NumberedItem> 2171 <Text id="mf-45">Open the file <Path>Greenstone → etc → main.cfg</Path> in a text editor. Locate the <AutoText text="macrofiles" type="italics"/> list:</Text> 2172 <Format> 2173 # The list of display macro files used by this receptionist<br/> 2174 macrofiles tip.dm style.dm base.dm query.dm help.dm pref.dm about.dm \<br/> 2175 document.dm browse.dm status.dm authen.dm users.dm html.dm \<br/> 2176 extlink.dm gsdl.dm extra.dm home.dm collect.dm docs.dm \<br/> 2177 bsummary.dm gti.dm gli.dm nav_css.dm usability.dm \<br/> 2178 ...<br/> 2179 </Format> 2180 <Text id="mf-46">Change the text <Format>home.dm</Format> to <Format>yourhome.dm</Format>. Save and close the file.</Text> 2181 </NumberedItem> 2182 <NumberedItem> 2183 <Text id="mf-47">Preview the newly structured home page in a web browser. (On Windows, restart the Greenstone library server.) Look at the file macros/yourhome.dm in a text editor to see hoe these changes are expressed.</Text> 2184 </NumberedItem> 2185 <NumberedItem> 2186 <Text id="mf-48">Reverse this last change by changing <Format>yourhome.dm</Format> back to <Format>home.dm</Format> in the file <Path>Greenstone → etc → main.cfg</Path>. You may also like to reverse the other changes you have made.</Text> 2187 <Comment> 2188 <Text id="mf-15a">The final part of this exercise looks at how we determined which images needed replacing, and which macro files should be edited.</Text> 2189 </Comment> 2190 </NumberedItem> 2191 <Heading> 2192 2192 <Text id="mf-63">How to determine which images to replace (advanced)</Text> 2193 2193 </Heading> 2194 2194 <NumberedItem> 2195 <Text id="mf-64">In the first partof this exercise we replaced the default background (<AutoText text="chalk.gif"/>) and header (<AutoText text="gsdlhead.gif"/>) images with new ones. To do this we needed to change the image names in the macro files. How did we know which images we were replacing and which macro files to edit? This exercise shows you how to find out.</Text>2196 </NumberedItem> 2197 <NumberedItem> 2198 <Text id="mf-65">To find out the names of the images to replace, go to the home page of your digital library in a browser. Right-click on the header image (<AutoText text="Greenstone digital library software" type="quoted"/>) and select "Save picture as". A dialog will pop up and will display the image name: < AutoText text="gsdlhead.gif" type="quoted"/> (or <AutoText text="gsdlhead-blue.gif" type="quoted"/> if you are using the new header). Click Cancel to close the dialog—you don't need to save the images. Do the same for the background image by right clicking on the left hand green (or blue) swirly bar. This time choose "Save background as" to find the name: <AutoText text="chalk.gif" type="quoted"/> (or <AutoText text="new_background.gif" type="quoted"/>), then click Cancel.</Text>2195 <Text id="mf-64">In the step 10 of this exercise we replaced the default background (<AutoText text="chalk.gif"/>) and header (<AutoText text="gsdlhead.gif"/>) images with new ones. To do this we needed to change the image names in the macro files. How did we know which images we were replacing and which macro files to edit? This exercise shows you how to find out.</Text> 2196 </NumberedItem> 2197 <NumberedItem> 2198 <Text id="mf-65">To find out the names of the images to replace, go to the home page of your digital library in a browser. Right-click on the header image (<AutoText text="Greenstone digital library software" type="quoted"/>) and select "Save picture as". A dialog will pop up and will display the image name: <i><AutoText text="gsdlhead.gif" /></i> (or <i><AutoText text="newheadimg.gif" /></i> if you are using the new header). Click Cancel to close the dialog—you don't need to save the images. Do the same for the background image by right clicking on the left hand green (or blue) swirly bar. This time choose "Save background as" to find the name: <i><AutoText text="chalk.gif" /></i> (or <i><AutoText text="newbgimg.gif" /></i>), then click Cancel.</Text> 2199 2199 </NumberedItem> 2200 2200 <NumberedItem> … … 2204 2204 <Text id="mf-67">Once you have identified the names of the images to be replaced, you need to find out where they occur in the macro files. To do this, search the macro files for the image names using the <AutoText text="find"/> program, which is run in a command prompt. Open a command prompt using <Menu>Start → Programs → Accessories → Command Prompt</Menu>, or <Menu>Start → Run</Menu> and enter <Command>cmd</Command> as the name of the program to run.</Text> 2205 2205 <Text id="mf-68">You can type <Command>find/?</Command> to see a description of the program and its arguments.</Text> 2206 <Text id="mf-69">To search the macro files for < AutoText text="gsdlhead.gif" type="quoted"/> type</Text>2206 <Text id="mf-69">To search the macro files for <i><AutoText text="gsdlhead.gif" /></i> type</Text> 2207 2207 <Command>find "gsdlhead.gif" "C:\Program Files\Greenstone\macros\*.dm"</Command> 2208 2208 <Text id="mf-70"><AutoText text="*.dm"/> means all files ending in <AutoText text=".dm"/>. A list of all macro files will be displayed, along with any matches. You will see that <Path>home.dm</Path> and <Path>exported_home.dm</Path> both contain <AutoText text="gsdlhead.gif"/>. <Path>home.dm</Path> in the one you want to edit—<Path>exported_home.dm</Path> is used for the home page when you export a collection to CD-ROM.</Text> 2209 <Text id="mf-71">Do the same thing for < AutoText text="chalk.gif" type="quoted"/>:</Text>2209 <Text id="mf-71">Do the same thing for <i><AutoText text="chalk.gif" /></i>:</Text> 2210 2210 <Command>find "chalk.gif" "C:\Program Files\Greenstone\macros\*.dm"</Command> 2211 <Text id="mf-72"><Path>base.dm</Path> is the only file that mentionsthis image.</Text>2211 <Text id="mf-72"><Path>base.dm</Path> and <Path>style.dm</Path> are the only files that mention this image.</Text> 2212 2212 <Text id="mf-73">Close the command prompt.</Text> 2213 2213 </NumberedItem> … … 2219 2219 </Title> 2220 2220 <SampleFiles folder="beatles"/> 2221 <Version initial="2.60" current="2. 71"/>2221 <Version initial="2.60" current="2.80"/> 2222 2222 <Content> 2223 2223 <NumberedItem> … … 2255 2255 <Prerequisite id="multimedia_collection_explore"/> 2256 2256 <SampleFiles folder="beatles"/> 2257 <Version initial="2.60" current="2. 71"/>2257 <Version initial="2.60" current="2.80"/> 2258 2258 <Content> 2259 2259 <Comment> … … 2302 2302 </BulletList> 2303 2303 <Text id="0566"><b>Build</b> the collection again, and <b>preview</b> it.</Text> 2304 <Text id="0567">Extracted metadata is unreliable. But it is very cheap! On the other hand, manually assigned metadata is reliable, but expensive. The previous section of this exercise has shown how to aim for the best of both worlds by using extracted metadata but correcting it when it is wrong. While this may not satisfy the professional librarian, it could provide a useful compromise for the music teacher who wants to get their collection together with a minimum of effort.</Text>2304 <Text id="0567">Extracted metadata is unreliable. But it is very cheap! On the other hand, manually assigned metadata is reliable, but expensive. The previous section of this exercise has shown how to aim for the best of both worlds by using extracted metadata but correcting it when it is wrong.</Text> 2305 2305 </NumberedItem> 2306 2306 <Heading> … … 2357 2357 <highlight>{If}{[dc.Format] eq 'Images',</highlight><br/> 2358 2358 <highlight>[srclink][thumbicon][/srclink],</highlight><br/> 2359 <highlight>[link][icon][/link]}}</highlight></td> <br/> 2359 <highlight>{If}{[dc.Format] eq 'Supplementary',</highlight><br/> 2360 <highlight>[srclink][srcicon][/srclink] [link][icon][/link],</highlight> 2361 <highlight>[link][icon][/link]}}}</highlight></td> <br/> 2360 2362 <td valign=top>[highlight]<br/> 2361 2363 {Or}{[dls.Title],[dc.Title],[Title],Untitled}<br/> … … 2529 2531 <NumberedItem> 2530 2532 <Text id="0646">Using the file browser, copy the <Path>images</Path> and <Path>macros</Path> folders from the <Path>advbeat_large</Path> folder into the <Path>smallbea</Path> folder. (It's OK to overwrite the existing <Path>images</Path> folder: the image in it is included in the folder being copied.) The <Path>images</Path> folder includes some useful icons, and the <Path>macros</Path> folder defines some macro names that use these images.</Text> 2531 <Text id="0646a">To see the macro definitions, open the collection in the L Ibrarian Interface (<Menu><AutoText key="glidict::Menu.File"/> → <AutoText key="glidict::Menu.File_Open"/></Menu>) and view the <AutoText key="glidict::CDM.GUI.Macros"/> section in the <AutoText key="glidict::GUI.Format"/> panel.</Text>2533 <Text id="0646a">To see the macro definitions, open the collection in the Librarian Interface (<Menu><AutoText key="glidict::Menu.File"/> → <AutoText key="glidict::Menu.File_Open"/></Menu>) and view the <AutoText key="glidict::CDM.GUI.Macros"/> section in the <AutoText key="glidict::GUI.Format"/> panel.</Text> 2532 2534 </NumberedItem> 2533 2535 <Heading> … … 2620 2622 </Title> 2621 2623 <SampleFiles folder="niupepa"/> 2622 <Version initial="2.60" current="2. 71"/>2624 <Version initial="2.60" current="2.80"/> 2623 2625 <Content> 2624 2626 <Comment> … … 2635 2637 </NumberedItem> 2636 2638 <NumberedItem> 2637 <Text id="0680">Some of the files you have just dragged in are the newspaper images; others are text files that contain the text extracted from these images. We want these to be processed by <AutoText text="PagedImgPlug"/>, not <AutoText text="ImagePlug"/> or <AutoText text="TEXTPlug"/>. Switch to the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel and delete <AutoText text="ImagePlug"/> and <AutoText text="TEXTPlug"/>. While you are at it, you could tidy things up by deleting <AutoText text="ZIPPlug"/> and all plugins from <AutoText text="HTMLPlug"/> to <AutoText text="NULPlug"/> as well, since they will not be used. <AutoText text="GAPlug"/> and <AutoText text="PagedImgPlug"/> remain.</Text>2639 <Text id="0680">Some of the files you have just dragged in are the newspaper images; others are text files that contain the text extracted from these images. We want these to be processed by <AutoText text="PagedImgPlug"/>, not <AutoText text="ImagePlug"/> or <AutoText text="TEXTPlug"/>. Switch to the <AutoText key="glidict::CDM.GUI.Plugins"/> section of the <AutoText key="glidict::GUI.Design"/> panel and <i>delete <AutoText text="ImagePlug"/> and <AutoText text="TEXTPlug"/></i>.</Text> 2638 2640 </NumberedItem> 2639 2641 <NumberedItem> … … 2641 2643 </NumberedItem> 2642 2644 <NumberedItem> 2643 <Text id="0678a">In the <AutoText key="glidict::CDM.GUI.Indexes"/> section, check the <AutoText key="glidict::CDM.LevelManager.Section"/> checkbox to build the indexes on section level as well as document level.</Text>2644 </NumberedItem>2645 <NumberedItem>2646 2645 <Text id="0681">Now go to the <AutoText key="glidict::GUI.Create"/> panel, <b>build</b> the collection and <b>preview</b> the result. Search for <AutoText text="waka" type="quoted"/> and view one of the titles listed (all three appear as <AutoText text="Te Whetu o Te Tau" type="italics"/>). Browse by <AutoText key="coredm::_Global:labelTitle_"/> and view one of the <AutoText text="Te Waka o Te Iwi" type="italics"/> newspapers. Note that only the <AutoText text="Te Whetu o Te Tau" type="italics"/> newspapers have text; <AutoText text="Te Waka o Te Iwi" type="italics"/> papers don't.</Text> 2647 2646 </NumberedItem> … … 2662 2661 </NumberedItem> 2663 2662 <NumberedItem> 2664 <Text id="0687">In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText key="metadata::ex.Title"/> classifier in the <AutoText key="glidict::CDM.FormatManager.Feature"/> list, and <AutoText text="VList"/> in the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> to add this format statment to your collection. Delete the contents of the <AutoText key="glidict::CDM.FormatManager.Editor"/> box, and add the following text. (This format statement can be copied and pasted from the file <Path>sample_files → niupepa → formats → titles_tweak.txt</Path>.)</Text> 2663 <Text id="0686a"><b>Build</b> the collection, and <b>preview</b> the <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list and the <AutoText key="coredm::_Global:labelDate_" type="italics"/> list.</Text> 2664 </NumberedItem> 2665 <NumberedItem> 2666 <Text id="0687">Now we change the format statement for <AutoText key="coredm::_Global:labelTitle_" type="italics"/> to display more information about the documents. In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText key="metadata::ex.Title"/> classifier in the <AutoText key="glidict::CDM.FormatManager.Feature"/> list, and <AutoText text="VList"/> in the <AutoText key="glidict::CDM.FormatManager.Part"/> list. Click <AutoText key="glidict::CDM.FormatManager.Add" type="button"/> to add this format statement to your collection. Delete the contents of the <AutoText key="glidict::CDM.FormatManager.Editor"/> box, and add the following text. (This format statement can be copied and pasted from the file <Path>sample_files → niupepa → formats → titles_tweak.txt</Path>.)</Text> 2665 2667 <Format> 2666 2668 <td valign="top">[link][icon][/link]</td><br/> 2667 2669 <td valign="top"><br/> 2668 2670 {If}{[numleafdocs],[ex.Title] ([numleafdocs]),<br/> 2669 {If}{[ex.Volume],Volume [ex.Volume] }<br/> 2670 {If}{[ex.Number],Number [ex.Number] }<br/> 2671 {If}{[ex.Date], [ex.Date]}}<br/> 2671 Volume [ex.Volume] Number [ex.Number] Date [ex.Date]}<br/> 2672 2672 </td> 2673 2673 </Format> 2674 2674 </NumberedItem> 2675 2675 <NumberedItem> 2676 <Text id="0690a"><b>Build</b> the collection, and <b>preview</b> the new <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list.</Text> 2677 <Text id="0687c">As a consequence of using the <AutoText text="AZCompactList"/> 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. It works by exploiting the fact that only bookshelf icons define <Format>[numleafdocs]</Format> metadata. For document nodes, Title is not displayed. Instead, Volume, Number and Date information are displayed if present.</Text> 2676 <Text id="0690a">Refresh in the web browser to view the new <AutoText key="coredm::_Global:labelTitle_" type="italics"/> list.</Text> 2677 <Text id="0687c">As a consequence of using the <AutoText text="AZCompactList"/> 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. It works by exploiting the fact that only bookshelf icons define <Format>[numleafdocs]</Format> metadata. For document nodes, Title is not displayed. Instead, Volume, Number and Date information are displayed.</Text> 2678 </NumberedItem> 2679 <NumberedItem> 2680 <Text id="0691">The <AutoText key="coredm::_Global:labelDate_" type="italics"/> list groups documents by date. A numeric date is displayed at the end of each document title, for example 18580601. This is in the Greenstone internal date format, which is crucial for the <AutoText text="DateList" /> classifier to correctly parse date metadata and generate an ordered date list. However, you can make the date look nice by adding a <AutoText text="[Format:]"/> macro to date metadata.</Text> 2681 </NumberedItem> 2682 <NumberedItem> 2683 <Text id="0691a">Now we format the date. In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText text="DateList" /> classifier <i>and set <AutoText key="glidict::CDM.FormatManager.Part"/> to <AutoText text="DateList"/></i>. Replace the last line</Text> 2684 <Format> 2685 <td>{Or}{[dc.Date],[exp.Date],[ex.Date]}</td> 2686 </Format> 2687 <Text id="0691b">with</Text> 2688 <Format> 2689 <td>{Or}{[dc.Date],[exp.Date],[format:ex.Date]}</td> 2690 </Format> 2691 <Text id="0691c">Refresh in the web browser to view the new <AutoText key="coredm::_Global:labelDate_" type="italics"/> list.</Text> 2678 2692 </NumberedItem> 2679 2693 <Heading> … … 2681 2695 </Heading> 2682 2696 <Comment> 2683 <Text id="0695">When you reach a newspaper, only its associated text is displayed. When either of the <AutoText text="Te Waka o Te Iwi"/> newspapers is accessed, the document view presents the message <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> .No scanned image information (screen-view resolution or otherwise) is shown, even though it has been computed and stored with the document. This can be fixed by a format statement that modifies the default behaviour for <AutoText text="DocumentText"/>.</Text>2684 </Comment> 2685 <NumberedItem> 2686 <Text id="0696">In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText text="DocumentText"/> format statement. The default format string displays the document's plain text, which, if there is none, is set to <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> .Change this to the following text. (This format statement can be copied and pasted from the file <Path>sample_files → niupepa → formats → doc_tweak.txt</Path>)</Text>2697 <Text id="0695">When you reach a newspaper, only its associated text is displayed. When either of the <AutoText text="Te Waka o Te Iwi"/> newspapers is accessed, the document view presents the message <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> No scanned image information (screen-view resolution or otherwise) is shown, even though it has been computed and stored with the document. This can be fixed by a format statement that modifies the default behaviour for <AutoText text="DocumentText"/>.</Text> 2698 </Comment> 2699 <NumberedItem> 2700 <Text id="0696">In the <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel, select the <AutoText text="DocumentText"/> format statement. The default format string displays the document's plain text, which, if there is none, is set to <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> Change this to the following text. (This format statement can be copied and pasted from the file <Path>sample_files → niupepa → formats → doc_tweak.txt</Path>)</Text> 2687 2701 <Format> 2688 2702 <table><tr><br/> … … 2692 2706 </Format> 2693 2707 <Comment> 2694 <Text id="0698">Including <Format>[screenicon]</Format> has the effect of embedding the screen-sized image generated by switching the <AutoText text="screenview"/> option on in <AutoText text="PagedImgPlug"/>. It is hyperlinked to the original image by the construct <Format>[srclink]...[/srclink]</Format>. </Text>2708 <Text id="0698">Including <Format>[screenicon]</Format> has the effect of embedding the screen-sized image generated by switching the <AutoText text="screenview"/> option on in <AutoText text="PagedImgPlug"/>. It is hyperlinked to the original image by the construct <Format>[srclink]...[/srclink]</Format>. This is a large image but it may be scaled by your browser.</Text> 2695 2709 </Comment> 2696 2710 <Text id="0698a">This modification will display screenview image, but does nothing about the dummy text <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/>, which will still be displayed. To get rid of this, edit the <AutoText text="DocumentText"/> format statement again and replace</Text> … … 2700 2714 <Text id="0698b">with</Text> 2701 2715 <Format> 2702 {If}{[ Text] ne "<AutoText key="perlmodules::BasPlug.dummy_text" type="plain"/> ",<td valign=top>[Text]</td>}2703 </Format> 2704 </NumberedItem> 2705 <NumberedItem> 2706 <Text id="0698c"><b>Preview</b> the collection and view one of the <AutoText text="Te Waka o Te Iwi"/> documents. The line <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> should now be gone. (Note that it important to get the text exactly right for this to work, including the space after the ".".)</Text>2716 {If}{[NoText] ne '1',<td valign=top>[Text]</td>} 2717 </Format> 2718 </NumberedItem> 2719 <NumberedItem> 2720 <Text id="0698c"><b>Preview</b> the collection and view one of the <AutoText text="Te Waka o Te Iwi"/> documents. The line <AutoText key="perlmodules::BasPlug.dummy_text" type="quoted"/> should now be gone.</Text> 2707 2721 </NumberedItem> 2708 2722 <Heading> … … 2716 2730 </NumberedItem> 2717 2731 <NumberedItem> 2732 <Text id="0690e"><b>Build</b> and <b>preview</b> the collection.</Text> 2733 </NumberedItem> 2734 <NumberedItem> 2718 2735 <Text id="0690d-1">Set the display text used for the level drop-down menu by going to the <AutoText key="glidict::CDM.GUI.SearchMetadata"/> section on the <AutoText key="glidict::GUI.Format"/> panel. Set the document level text to "newspaper", and the section level text to "page".</Text> 2719 </NumberedItem> 2720 <NumberedItem> 2721 <Text id="0690e"><b>Build</b> and <b>preview</b> the collection. Compare searching at "newspaper" level compared to "page" level. A useful search term for this collection is <AutoText text="aroha" type="quoted"/>.</Text> 2722 </NumberedItem> 2723 <NumberedItem> 2724 <Text id="0690f">You will notice that when searching for individual pages, the newspaper image is displayed in the search results. As these images are very large, this is not very useful. Go to <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel in the Librarian Interface and select the <AutoText text="VList"/> format statement from the list of assigned format statements. Remove the second line from the <AutoText key="glidict::CDM.FormatManager.Editor"/>:</Text> 2736 <Text id="0690d-2">Refresh in your web browser. Compare searching at "newspaper" level with searching at "page" level. A useful search term for this collection is <AutoText text="aroha" type="quoted"/>.</Text> 2737 </NumberedItem> 2738 <NumberedItem> 2739 <Text id="0690f">You will notice that when searching for individual pages, the newspaper image is displayed in the search results. As these images are very large, this is not very useful. Go to <AutoText key="glidict::CDM.GUI.Formats"/> section of the <AutoText key="glidict::GUI.Format"/> panel in the Librarian Interface, choose <AutoText key="glidict::CDM.FormatManager.AllFeatures"/> in <AutoText key="glidict::CDM.FormatManager.Feature"/> list, and select the <AutoText text="VList"/> format statement from the list of assigned format statements. Remove the second line from the <AutoText key="glidict::CDM.FormatManager.Editor"/>:</Text> 2725 2740 <Format> 2726 2741 <td valign="top">[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]}[ex./srclink]</td> 2727 2742 </Format> 2728 <Text id="0690f-1">While we are here, lets remove the filename from the display. Remove the following from the last line:</Text> 2743 <Text id="0690f-1">The reason why this is causing a problem is that the <AutoText text="PagedImgPlug"/> does not produce ex.thumbicon, and as a consequence this format statement displays ex.srcicon, which is very large </Text> 2744 <Text id="0690f-2">While we are here, let's remove the filename from the display. Remove the following from the last line of the format string:</Text> 2729 2745 <Format> 2730 2746 {If}{[ex.Source],<br><i>([ex.Source])</i>} … … 2740 2756 <td valign="top">[link][icon][/link]</td><br/> 2741 2757 <td valign="top"><br/> 2742 {If}{[parent:ex.Title],[parent:ex.Title]<br/> 2743 {If}{[parent:ex.Volume],Volume [parent:ex.Volume] }<br/> 2744 {If}{[parent:ex.Number],Number [parent:ex.Number]}: Page [ex.Title],<br/> 2745 [ex.Title] {If}{[ex.Volume], Volume [ex.Volume] }<br/> 2746 {If}{[ex.Number], Number [ex.Number] }}<br/> 2747 <br/><i>({Or}{[parent:ex.Date],[ex.Date]})</i></td><br/> 2758 {If}{[parent:ex.Title],[parent:ex.Title] Volume [parent:ex.Volume] Number [parent:ex.Number]: Page [ex.Title],<br/> 2759 [ex.Title] Volume [ex.Volume] Number [ex.Number]}<br/> 2760 <br/><i>({Or}{[parent:ex.Date],[ex.Date],undated})</i></td><br/> 2748 2761 </td> 2749 2762 </Format> 2750 <Text id="0690l"><b>Preview</b> the search results. Items display newspaper title, Volume, Number and Date if available, and pages also display the page number.</Text> 2751 </NumberedItem> 2752 <Comment> 2753 <Text id="0701">In the collection you have just built, newspapers are grouped by series title, and dates are supplied alongside each one to distinguish it from others in the same series. Users can browse chronologically by date, and when a newspaper page is viewed a preview image is shown on the left that displays the original high-resolution version when clicked, accompanied on the right by the plain-text version of that newspaper (if available).</Text> 2763 <Text id="0690l"><b>Preview</b> the search results. Items display newspaper title, Volume, Number and Date, and pages also display the page number.</Text> 2764 </NumberedItem> 2765 <Comment> 2766 <Text id="0701">The collection you have just built involves a fairly complex document structure. There are two series of newspapers, <AutoText text="Te Waka"/> and <AutoText text="Te Whetu"/>.</Text> 2767 </Comment> 2768 <Comment> 2769 <Text id="0701-a">In the <AutoText text="Te Waka"/> series there are two actual newspapers, <AutoText text="Volume 1" type="italics"/> Numbers 1 and 2. Number 1 has 4 pages, numbered 1, 2, 3, 4; Number 2 has 4 pages, numbered 5, 6, 7, 8. The page numbers increase consecutively through each volume, despite the fact that the volume is divided into different Numbers. Each page in the Te Waka series is represented by a single file, a GIF image of the page.</Text> 2770 </Comment> 2771 <Comment> 2772 <Text id="0701-b">The <AutoText text="Te Whetu"/> series has three actual newspapers, <AutoText text="Volume 1" type="italics"/> Numbers 1, 2, and 3. Number 1 has 4 pages, numbered 1, 2, 3, 4; Number 2 has 5 pages, numbered 5, 6, 7, 8, 9; Number 3 has 5 pages, numbered 10, 11, 12, 13, 14. Again the page numbers increase consecutively through each volume. Each page in this series is represented by two files, a GIF image of the page and a text file containing the OCRâd text that appears on it.</Text> 2773 </Comment> 2774 <Comment> 2775 <Text id="0701-c">The key to this structure is in the respective <i>.item</i> files. Here is a synopsis of the information they contain:</Text> 2776 <Format> 2777 (9-1-1) Te Waka Volume 1 Number 1<br/> 2778 p.1 gif<br/> 2779 p.2 gif<br/> 2780 p.3 gif<br/> 2781 p.4 gif<br/> 2782 (9-1-2) Te Waka Volume 1 Number 2<br/> 2783 p.5 gif<br/> 2784 p.6 gif<br/> 2785 p.7 gif<br/> 2786 p.8 gif<br/> 2787 (10-1-1) Te Whetu Volume 1 Number 1<br/> 2788 p.1 gif text<br/> 2789 p.2 gif text<br/> 2790 p.3 gif text<br/> 2791 p.4 gif text<br/> 2792 (10-1-2) Te Whetu Volume 1 Number 2<br/> 2793 p.5 gif text<br/> 2794 âŠ<br/> 2795 p.9 gif text<br/> 2796 (10-1-3) Te Whetu Volume 1 Number 3<br/> 2797 p.10 gif text<br/> 2798 âŠ<br/> 2799 p.14 gif text<br/> 2800 </Format> 2754 2801 </Comment> 2755 2802 </Content> … … 2761 2808 <SampleFiles folder="niupepa"/> 2762 2809 <Prerequisite id="scanned_image_collection"/> 2763 <Version initial="2.70" current="2. 71"/>2810 <Version initial="2.70" current="2.80"/> 2764 2811 <Content> 2765 2812 <Comment> … … 2815 2862 <Text id="sc21">The second style is an extended format, and uses XML. It allows a hierarchy of pages, and metadata specification at the page level as well as at the document level. In this section, we add in two newspapers which use XML-based item files.</Text> 2816 2863 <NumberedItem> 2817 <Text id="sc22">In the <AutoText key="glidict::GUI.Gather"/> panel, add the folder <Path>sample_files → niupepa → new_papers → xml</Path> to your collection. </Text>2864 <Text id="sc22">In the <AutoText key="glidict::GUI.Gather"/> panel, add the folder <Path>sample_files → niupepa → new_papers → xml</Path> (you need to add the <AutoText text="xml"/> folder, not the <AutoText text="23"/> folder) to your collection. </Text> 2818 2865 </NumberedItem> 2819 2866 <NumberedItem> … … 2867 2914 {If}{[srcicon],_document:viewfullsize_}<br/> 2868 2915 {If}{[screenicon],_document:viewpreview_}<br/> 2869 {If}{[ Text] ne 'This document has no text.',_document:viewtext_}<br/>2916 {If}{[NoText] ne '1',_document:viewtext_}<br/> 2870 2917 </div><br/> 2871 2918 <div class="toc">[DocTOC]</div><br/> … … 2881 2928 {If}{_cgiargp_ eq 'fullsize',[srcicon],<br/> 2882 2929 {If}{_cgiargp_ eq 'preview',[screenicon],<br/> 2883 {If}{[ Text] ne \'This document has no text. \',[Text],[screenicon]}}}2930 {If}{[NoText] ne '1',[Text],[screenicon]}}} 2884 2931 </Format> 2885 2932 <Text id="sc34b">This format statement changes the display based on the <AutoText text="p" type="quoted"/> argument (<Format>_cgiargp_</Format>). This is not used normally for document display, so we can use it here to switch between full size image (<Format>[srcicon]</Format>), preview size image (<Format>[screenicon]</Format>) and text (<Format>[Text]</Format>) versions of each page.</Text> … … 2895 2942 </Title> 2896 2943 <SampleFiles folder="oai"/> 2897 <Version initial="2.60" current="2. 71"/>2944 <Version initial="2.60" current="2.80"/> 2898 2945 <Content> 2899 2946 <Comment> … … 2995 3042 </Title> 2996 3043 <Prerequisite id="OAI_collection"/> 2997 <Version initial="2.60" current="2. 71"/>3044 <Version initial="2.60" current="2.80"/> 2998 3045 <Content> 2999 3046 <Comment> … … 3020 3067 </NumberedItem> 3021 3068 <NumberedItem> 3022 <Text id="oai-8">Downloaded files are stored in a top-level folder called <AutoText key="glidict::Tree.DownloadedFiles"/> that appears on the left-hand side of the <AutoText key="glidict::GUI.Gather"/> panel. These canfiles can then be added to a collection.</Text>3069 <Text id="oai-8">Downloaded files are stored in a top-level folder called <AutoText key="glidict::Tree.DownloadedFiles"/> that appears on the left-hand side of the <AutoText key="glidict::GUI.Gather"/> panel. These files can then be added to a collection.</Text> 3023 3070 </NumberedItem> 3024 3071 <Heading> … … 3075 3122 <Text id="0750">Use METS as Greenstone's Internal Representation</Text> 3076 3123 </Title> 3077 <Version initial="2.60" current="2. 71"/>3124 <Version initial="2.60" current="2.80"/> 3078 3125 <Content> 3079 3126 <NumberedItem> 3080 <Text id="0751">In the Greenstone Librarian Interface, open up one of your existing collections, for example the <b> hobbits</b> collection.</Text>3127 <Text id="0751">In the Greenstone Librarian Interface, open up one of your existing collections, for example the <b>Small HTML Collection</b> collection.</Text> 3081 3128 </NumberedItem> 3082 3129 <Comment> … … 3105 3152 </Title> 3106 3153 <SampleFiles folder="dspace"/> 3107 <Version initial="2.60" current="2. 71"/>3154 <Version initial="2.60" current="2.80"/> 3108 3155 <Content> 3109 3156 <NumberedItem> … … 3113 3160 <Text id="0763">Start a <b>new collection</b> called <b>StoneD</b> and fill out its fields appropriately. Leave the metadata set at Dublin Core, the default.</Text> 3114 3161 </NumberedItem> 3162 <!-- don't need to remove the plugins --> 3163 <!-- 3115 3164 <NumberedItem> 3116 3165 <Text id="0764">Switch to the <AutoText key="glidict::GUI.Design"/> panel and select the <AutoText key="glidict::CDM.GUI.Plugins"/> section on the left-hand side. <b>Remove</b> <AutoText text="ZIPPlug" />, <AutoText text="TEXTPlug" />, <AutoText text="HTMLPlug" />, <AutoText text="EMAILPlug" />, <AutoText text="PSPlug" />, <AutoText text="ImagePlug" />, <AutoText text="ISISPlug" /> and <AutoText text="NULPlug" />. Strictly speaking we do not need to remove these, however it reduces clutter.</Text> 3117 3166 </NumberedItem> 3167 --> 3118 3168 <NumberedItem> 3119 3169 <Text id="0765">Now add <AutoText text="DSpacePlug" />. Leave the plugin options at their defaults and press <AutoText key="glidict::General.OK" type="button"/>.</Text> … … 3192 3242 </Title> 3193 3243 <Prerequisite id="dspace_to_greenstone"/> 3194 <Version initial="2.60" current="2. 71"/>3244 <Version initial="2.60" current="2.80"/> 3195 3245 <Content> 3196 3246 <Comment> … … 3235 3285 <Text id="gems-1">Editing metadata sets</Text> 3236 3286 </Title> 3237 <Version initial="2.70w" current="2. 71"/>3287 <Version initial="2.70w" current="2.80"/> 3238 3288 <Content> 3239 3289 <Text id="gems-2">GEMS (Greenstone Editor for Metadata Sets) can be used to modify existing metadata sets or create new ones. GEMS is launched from the Librarian Interface when you want to create a new metadata set, or edit an existing one. In this exercise, we run GEMS outside of the Librarian Interface.</Text> … … 3252 3302 </Heading> 3253 3303 <NumberedItem> 3254 <Text id="gems-8">In this exercise, we will create a new metadata set. In order to save time, we will base it on an existing one: Development Library Subset. From the <AutoText key="glidict::Menu.File"/> menu, select <AutoText key="glidict::Menu.File _New"/> (<AutoText key="glidict::Menu.File"/> → <AutoText key="glidict::Menu.File_New"/>). A popup window appears: <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Title"/>. Fill in the fields. Use <AutoText text="My Metadata Set" type="quoted"/> for the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Metadata_Title"/>, <AutoText text="my" type="quoted"/> for the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Metadata_Namespace"/>, and select "Development Library Subset Example Metadata" from the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Base_MetadataSet"/> drop down list. Click <AutoText key="glidict::General.OK" type="button"/>.</Text>3304 <Text id="gems-8">In this exercise, we will create a new metadata set. In order to save time, we will base it on an existing one: Development Library Subset. From the <AutoText key="glidict::Menu.File"/> menu, select <AutoText key="glidict::Menu.File"/> → <AutoText key="glidict::Menu.File_New"/>. A popup window appears: <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Title"/>. Fill in the fields. Use <AutoText text="My Metadata Set" type="quoted"/> for the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Metadata_Title"/>, <AutoText text="my" type="quoted"/> for the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Metadata_Namespace"/>, and select "Development Library Subset Example Metadata" from the <AutoText key="glidict::GEMS.NewMetadataSetPrompt.Base_MetadataSet"/> drop down list. Click <AutoText key="glidict::General.OK" type="button"/>.</Text> 3255 3305 </NumberedItem> 3256 3306 <NumberedItem> … … 3264 3314 </NumberedItem> 3265 3315 <NumberedItem> 3266 <Text id="gems-12">In the right hand side, the default attributes will appear for the new element. "Label" and "definition" are used in the Librarian Interface when displaying metadata elements and their descriptions . These attributes can be set in multiple languages.</Text>3316 <Text id="gems-12">In the right hand side, the default attributes will appear for the new element. "Label" and "definition" are used in the Librarian Interface when displaying metadata elements and their descriptions (the "definition" is shown as additional text for the element). These attributes can be set in multiple languages.</Text> 3267 3317 </NumberedItem> 3268 3318 <NumberedItem> -
documentation/trunk/tutorials/xml-source/tutorial_es.xml
r11967 r17494 4 4 <!ENTITY rarr "→"> 5 5 <!ENTITY mdash "—"> 6 <!ENTITY copy "©"> 6 7 ]> 7 8 <TutorialList> … … 18 19 <Text id="wiki">Back to wiki</Text><Updated date="2-Mar-2006"/> 19 20 <Text id="print">Imprima versión</Text><Updated date="29-Mar-2006"/> 21 <Text id="copyright">Copyright © 2005 2006 2007 by the <Link url="http://www.nzdl.org">New Zealand Digital Library Project</Link> at <Link url="http://www.waikato.ac.nz">the University of Waikato</Link>, New Zealand<br/>Permission is granted to copy, distribute and/or modify this document under the terms of the <Link url="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License</Link>, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled <Link url="http://greenstonewiki.cs.waikato.ac.nz/wiki/gsdoc/GNUFDL.html">âGNU Free Documentation License.â</Link></Text> 20 22 </SupplementaryText> 21 23 <Comment> -
documentation/trunk/tutorials/xml-source/tutorial_fr.xml
r11967 r17494 4 4 <!ENTITY rarr "→"> 5 5 <!ENTITY mdash "—"> 6 <!ENTITY copy "©"> 6 7 ]> 7 8 <TutorialList> … … 18 19 <Text id="wiki">Back to wiki</Text><Updated date="2-Mar-2006"/> 19 20 <Text id="print">Imprimer version</Text><Updated date="2-Apr-2006"/> 21 <Text id="copyright">Copyright © 2005 2006 2007 by the <Link url="http://www.nzdl.org">New Zealand Digital Library Project</Link> at <Link url="http://www.waikato.ac.nz">the University of Waikato</Link>, New Zealand<br/>Permission is granted to copy, distribute and/or modify this document under the terms of the <Link url="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License</Link>, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled <Link url="http://greenstonewiki.cs.waikato.ac.nz/wiki/gsdoc/GNUFDL.html">âGNU Free Documentation License.â</Link></Text> 20 22 </SupplementaryText> 21 23 <Comment> -
documentation/trunk/tutorials/xml-source/tutorial_ru.xml
r11967 r17494 4 4 <!ENTITY rarr "→"> 5 5 <!ENTITY mdash "—"> 6 <!ENTITY copy "©"> 6 7 ]> 7 8 <TutorialList> … … 18 19 <Text id="wiki">Back to wiki</Text><Updated date="2-Mar-2006"/> 19 20 <Text id="print">ÐеÑÑÐžÑ ÐŽÐ»Ñ Ð¿ÐµÑаÑО</Text><Updated date="29-Mar-2006"/> 21 <Text id="copyright">Copyright © 2005 2006 2007 by the <Link url="http://www.nzdl.org">New Zealand Digital Library Project</Link> at <Link url="http://www.waikato.ac.nz">the University of Waikato</Link>, New Zealand<br/>Permission is granted to copy, distribute and/or modify this document under the terms of the <Link url="http://www.gnu.org/licenses/fdl.html">GNU Free Documentation License</Link>, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled <Link url="http://greenstonewiki.cs.waikato.ac.nz/wiki/gsdoc/GNUFDL.html">âGNU Free Documentation License.â</Link></Text> 20 22 </SupplementaryText> 21 23 <Comment>
Note:
See TracChangeset
for help on using the changeset viewer.