1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
2 | <CollectionConfig xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:gslib="http://www.greenstone.org/skinning">
|
---|
3 | <metadataList>
|
---|
4 | <metadata name="creator"></metadata>
|
---|
5 | <metadata name="maintainer"></metadata>
|
---|
6 | <metadata name="public">true</metadata>
|
---|
7 | </metadataList>
|
---|
8 | <displayItemList>
|
---|
9 | <displayItem assigned="true" lang="en" name="name">tipple-waiata</displayItem>
|
---|
10 | <displayItem assigned="true" lang="en" name="description"></displayItem>
|
---|
11 | <!-- shortDescription is used as a tooltip for collection icon on home page-->
|
---|
12 | <displayItem assigned="true" lang="en" name="shortDescription">tipple-waiata</displayItem>
|
---|
13 | </displayItemList>
|
---|
14 | <!-- Global format statement -->
|
---|
15 | <format>
|
---|
16 | <gsf:template name="choose-title">
|
---|
17 | <gsf:choose-metadata>
|
---|
18 | <gsf:metadata name="dc.Title"/>
|
---|
19 | <gsf:metadata name="exp.Title"/>
|
---|
20 | <gsf:metadata name="ex.dc.Title"/>
|
---|
21 | <gsf:metadata name="Title"/>
|
---|
22 | <gsf:default>Untitled</gsf:default>
|
---|
23 | </gsf:choose-metadata>
|
---|
24 | </gsf:template>
|
---|
25 | <!-- modify the collection description template to output the "this collection contains X documents and was last built Y days ago" message -->
|
---|
26 | <xsl:template name="coll-description">
|
---|
27 | <p><gslib:collectionDescriptionTextAndServicesLinks/></p>
|
---|
28 | <xsl:variable name="raw_date"><gslib:collectionMeta name="buildDate"/></xsl:variable>
|
---|
29 | <xsl:variable name="formatted_date"><xsl:value-of select="util:formatTimeStamp($raw_date, 0, 3, /page/@lang)"/></xsl:variable>
|
---|
30 | <xsl:variable name="numdocs"><gslib:collectionMeta name="numDocs"/></xsl:variable>
|
---|
31 | <p><xsl:value-of select="util:getInterfaceText($interface_name, /page/@lang, 'about.standarddescriptiondays', concat($numdocs, ';', $formatted_date))"/></p>
|
---|
32 | </xsl:template>
|
---|
33 | </format>
|
---|
34 | <search type="lucene">
|
---|
35 | <level name="document">
|
---|
36 | <displayItem lang="en" name="name">document</displayItem>
|
---|
37 | </level>
|
---|
38 | <level name="section">
|
---|
39 | <displayItem lang="en" name="name">section</displayItem>
|
---|
40 | </level>
|
---|
41 | <defaultLevel name="document"/>
|
---|
42 | <index name="text">
|
---|
43 | <displayItem lang="en" name="name">text</displayItem>
|
---|
44 | </index>
|
---|
45 | <index name="dc.Title,ex.dc.Title,Title">
|
---|
46 | <displayItem lang="en" name="name">titles</displayItem>
|
---|
47 | </index>
|
---|
48 | <index name="Type">
|
---|
49 | <displayItem lang="en" name="name">types</displayItem>
|
---|
50 | </index>
|
---|
51 | <defaultIndex name="text"/>
|
---|
52 | <sort name="rank">
|
---|
53 | <displayItem lang="en" name="name">rank</displayItem>
|
---|
54 | </sort>
|
---|
55 | <sort name="none">
|
---|
56 | <displayItem lang="en" name="name">natural (build) order</displayItem>
|
---|
57 | </sort>
|
---|
58 | <searchType name="plain"/>
|
---|
59 | <searchType name="simpleform"/>
|
---|
60 | <searchType name="advancedform"/>
|
---|
61 | <format>
|
---|
62 | <gsf:template match="documentNode">
|
---|
63 | <td valign="top">
|
---|
64 | <gsf:link type="document">
|
---|
65 | <gsf:icon type="document"/>
|
---|
66 | </gsf:link>
|
---|
67 | </td>
|
---|
68 | <td>
|
---|
69 | <gsf:link type="document">
|
---|
70 | <xsl:call-template name="choose-title"/>
|
---|
71 | </gsf:link>
|
---|
72 | </td>
|
---|
73 | </gsf:template>
|
---|
74 | </format>
|
---|
75 | </search>
|
---|
76 |
|
---|
77 | <infodb type="jdbm"/>
|
---|
78 |
|
---|
79 | <import>
|
---|
80 | <pluginList>
|
---|
81 | <plugin name="ZIPPlugin"/>
|
---|
82 | <plugin name="GreenstoneXMLPlugin"/>
|
---|
83 | <plugin name="TippleExportJSONPlugin"/>
|
---|
84 | <plugin name="TextPlugin"/>
|
---|
85 | <plugin name="HTMLPlugin"/>
|
---|
86 | <plugin name="EmailPlugin"/>
|
---|
87 | <plugin name="PDFv2Plugin"/>
|
---|
88 | <!-- Configuring an UnknownConverterPlugin for docx processing with Tika -->
|
---|
89 | <plugin name="UnknownConverterPlugin">
|
---|
90 | <option name="-exec_cmd" value="java -jar %%GSDLHOME/ext/tika/tika-app.jar --html --pretty-print --encoding=UTF-8 %%INPUT_FILE > %%OUTPUT"/>
|
---|
91 | <option name="-convert_to" value="html"/>
|
---|
92 | <option name="-mime_type" value="application/vnd.openxmlformats-officedocument.wordprocessingml.document"/>
|
---|
93 | <option name="-srcicon" value="icondocx"/>
|
---|
94 | <option name="-process_extension" value="docx"/>
|
---|
95 | </plugin>
|
---|
96 | <!-- If you have Tesseract installed (for linux 64 bit machines, there's a tesseract tarball available
|
---|
97 | for download from http://trac.greenstone.org/browser/gs2-extensions/tesseract/trunk/tesseract-linux-x64.tar.gz
|
---|
98 | Untested: for windows, you can try installing Tesseract from Win binaries at https://github.com/UB-Mannheim/tesseract/wiki
|
---|
99 | For Windows and Mac, be sure to add tesseract's bin folder to your PATH and also set the TESSDATA_PREFIX environment variable to
|
---|
100 | the folder "tessdata" wherein you also need to have the "<3-letter-langcode>.traineddata" files for the languages you want
|
---|
101 | to OCR.) The Linux 64 bit tesseract extension tarball already does all this for you.
|
---|
102 | Once you have Tesseract installed, you can activate the following UnknownConverterPlugin to use Tika with Tesseract to OCR PDFs
|
---|
103 | that contain images by removing the XML comment symbols.
|
---|
104 | -->
|
---|
105 | <!--
|
---|
106 | <plugin name="UnknownConverterPlugin">
|
---|
107 | <option name="-exec_cmd" value="java -jar $GSDLHOME/ext/tika/tika-app-*.jar --config=$GSDLHOME/ext/tika/ocr-pdfs-config.xml --html %%INPUT_FILE > %%OUTPUT"/>
|
---|
108 | <option name="-convert_to" value="html"/>
|
---|
109 | <option name="-mime_type" value="application/pdf"/>
|
---|
110 | <option name="-srcicon" value="iconpdf"/>
|
---|
111 | <option name="-process_extension" value="pdf"/>
|
---|
112 | </plugin>
|
---|
113 | -->
|
---|
114 | <plugin name="RTFPlugin"/>
|
---|
115 | <plugin name="WordPlugin"/>
|
---|
116 | <plugin name="PostScriptPlugin"/>
|
---|
117 | <plugin name="PowerPointPlugin"/>
|
---|
118 | <plugin name="ExcelPlugin"/>
|
---|
119 | <plugin name="ImagePlugin"/>
|
---|
120 | <plugin name="ISISPlugin"/>
|
---|
121 | <plugin name="NulPlugin"/>
|
---|
122 | <plugin name="OAIPlugin"/>
|
---|
123 | <plugin name="MetadataXMLPlugin"/>
|
---|
124 | <plugin name="ArchivesInfPlugin"/>
|
---|
125 | <plugin name="DirectoryPlugin"/>
|
---|
126 | </pluginList>
|
---|
127 | </import>
|
---|
128 | <browse>
|
---|
129 | <classifier name="List">
|
---|
130 | <option name="-metadata" value="dc.Title,Title"/>
|
---|
131 | <option name="-buttonname" value="Titles"/>
|
---|
132 | <option name="-partition_type_within_level" value="approximate_size"/>
|
---|
133 | <option name="-numeric_partition_type_within_level" value="approximate_size"/>
|
---|
134 | <!-- only use one dc.Title/Title value. change to allvalues to use all of them.-->
|
---|
135 | <option name="-metadata_selection_mode_within_level" value="firstvalue"/>
|
---|
136 | <option name="-bookshelf_type" value="duplicate_only"/>
|
---|
137 | <!--
|
---|
138 | If you are classifying by multiple title values for each document, then
|
---|
139 | (1) edit above line to: <option name="-metadata_selection_mode_within_level" value="allvalues"/>
|
---|
140 | (2) create a custom <format> statement immediately below this <option> element,
|
---|
141 | and copy the existing browse <format>'s <gsf:template match="documentNode"> into it
|
---|
142 | (3) then change its choose-title line (<xsl:call-template name="choose-title"/>)
|
---|
143 | to the following (note pos=classifiedBy) preceded by the XML comment:
|
---|
144 | Instead of using choose-title here, we want to display the title that the document was classified on
|
---|
145 | <gsf:metadata name="dc.Title,Title" pos="classifiedBy"/>
|
---|
146 | -->
|
---|
147 | <!--<format>
|
---|
148 | <gsf:template match="documentNode">
|
---|
149 | <td valign="top">
|
---|
150 | <gsf:link type="document">
|
---|
151 | <gsf:icon type="document"/>
|
---|
152 | </gsf:link>
|
---|
153 | </td>
|
---|
154 | <td valign="top">
|
---|
155 | <gsf:link type="source">
|
---|
156 | <gsf:choose-metadata>
|
---|
157 | <gsf:metadata name="thumbicon"/>
|
---|
158 | <gsf:metadata name="srcicon"/>
|
---|
159 | </gsf:choose-metadata>
|
---|
160 | </gsf:link>
|
---|
161 | </td>
|
---|
162 | <td valign="top">
|
---|
163 | <gsf:link type="document">
|
---|
164 | Instead of using choose-title here, we want to display the title that the document was classified on
|
---|
165 | <gsf:metadata name="dc.Title,Title" pos="classifiedBy"/>
|
---|
166 | <gsf:switch>
|
---|
167 | <gsf:metadata name="Source"/>
|
---|
168 | <gsf:when test="exists"><br/><i>(<gsf:metadata name="Source"/>)</i></gsf:when>
|
---|
169 | </gsf:switch>
|
---|
170 | </gsf:link>
|
---|
171 | </td>
|
---|
172 | </gsf:template>
|
---|
173 | </format>
|
---|
174 | -->
|
---|
175 | </classifier>
|
---|
176 | <classifier name="List">
|
---|
177 | <option name="-metadata" value="Type"/>
|
---|
178 | <option name="-buttonname" value="Types"/>
|
---|
179 | <option name="-partition_type_within_level" value="approximate_size"/>
|
---|
180 | <option name="-numeric_partition_type_within_level" value="approximate_size"/>
|
---|
181 | <option name="-bookshelf_type" value="always"/>
|
---|
182 |
|
---|
183 | <format>
|
---|
184 | <gsf:template match="documentNode">
|
---|
185 | <td valign="top">
|
---|
186 | <gsf:link type="document">
|
---|
187 | <gsf:icon type="document"/>
|
---|
188 | </gsf:link>
|
---|
189 | </td>
|
---|
190 | <td valign="top">
|
---|
191 | <gsf:link type="source">
|
---|
192 | <gsf:choose-metadata>
|
---|
193 | <gsf:metadata name="thumbicon"/>
|
---|
194 | <gsf:metadata name="srcicon"/>
|
---|
195 | </gsf:choose-metadata>
|
---|
196 | </gsf:link>
|
---|
197 | </td>
|
---|
198 | <td valign="top">
|
---|
199 | <gsf:link type="document">
|
---|
200 | <!-- Defined in the global format statement -->
|
---|
201 | <xsl:call-template name="choose-title"/>
|
---|
202 | </gsf:link>
|
---|
203 | </td>
|
---|
204 | </gsf:template>
|
---|
205 | </format>
|
---|
206 | </classifier>
|
---|
207 | <format>
|
---|
208 | <gsf:template match="documentNode">
|
---|
209 | <td valign="top">
|
---|
210 | <gsf:link type="document">
|
---|
211 | <gsf:icon type="document"/>
|
---|
212 | </gsf:link>
|
---|
213 | </td>
|
---|
214 | <td valign="top">
|
---|
215 | <gsf:link type="source">
|
---|
216 | <gsf:choose-metadata>
|
---|
217 | <gsf:metadata name="thumbicon"/>
|
---|
218 | <gsf:metadata name="srcicon"/>
|
---|
219 | </gsf:choose-metadata>
|
---|
220 | </gsf:link>
|
---|
221 | </td>
|
---|
222 | <td valign="top">
|
---|
223 | <gsf:link type="document">
|
---|
224 | <!-- Defined in the global format statement -->
|
---|
225 | <xsl:call-template name="choose-title"/>
|
---|
226 | <gsf:switch>
|
---|
227 | <gsf:metadata name="Type"/>
|
---|
228 | <gsf:when test="exists"> <i>(<gsf:metadata name="Type"/>)</i></gsf:when>
|
---|
229 | </gsf:switch>
|
---|
230 | </gsf:link>
|
---|
231 | </td>
|
---|
232 | </gsf:template>
|
---|
233 | <gsf:template match="classifierNode[@classifierStyle = 'VList']">
|
---|
234 | <td valign="top">
|
---|
235 | <gsf:link type="classifier" style="static">
|
---|
236 | <gsf:icon type="classifier"/>
|
---|
237 | </gsf:link>
|
---|
238 | </td>
|
---|
239 | <td valign="top">
|
---|
240 | <gsf:link type="classifier">
|
---|
241 | <gsf:metadata name="Title"/>
|
---|
242 | </gsf:link>
|
---|
243 | </td>
|
---|
244 | </gsf:template>
|
---|
245 | <gsf:template match="classifierNode[@classifierStyle = 'HList']">
|
---|
246 | <gsf:link type="classifier" style="static">
|
---|
247 | <gsf:metadata name="Title"/>
|
---|
248 | </gsf:link>
|
---|
249 | </gsf:template>
|
---|
250 | </format>
|
---|
251 | </browse>
|
---|
252 | <display>
|
---|
253 | <format>
|
---|
254 | <gsf:option name="TOC" value="true"/>
|
---|
255 | <gsf:option name="allowUserComments" value="false"/>
|
---|
256 | <gsf:option name="allowDocumentEditing" value="true"/>
|
---|
257 | <gsf:option name="allowMapGPSEditing" value="true"/>
|
---|
258 | <!--
|
---|
259 | Overwriting this template allows you to change the heading of the document.
|
---|
260 | -->
|
---|
261 | <!--
|
---|
262 | <gsf:template name="documentHeading">
|
---|
263 | <span style="font-weight:bold; font-size: 120%;">
|
---|
264 | <xsl:call-template name="choose-title"/>
|
---|
265 | </span>
|
---|
266 | </gsf:template>
|
---|
267 | -->
|
---|
268 |
|
---|
269 | <!--
|
---|
270 | Overwriting this template can be used to redefine the content of the whole document.
|
---|
271 | This is useful for simple documents, but not recommended for more complex documents
|
---|
272 | (e.g. hierachical and paged documents) as it can prevent any sub-sections from showing.
|
---|
273 | -->
|
---|
274 |
|
---|
275 | <gsf:template name="documentContent">
|
---|
276 | <script type="text/javascript" src="sites/{$site_name}/collect/{$collName}/script/document_extra.js"><xsl:text> </xsl:text></script>
|
---|
277 |
|
---|
278 | <div id="gs-document">
|
---|
279 | <xsl:call-template name="documentPre"/>
|
---|
280 |
|
---|
281 | <gsf:switch>
|
---|
282 | <gsf:when name="Type" test="equals">
|
---|
283 | <gsf:div>Type: <gsf:metadata name="Type"/></gsf:div>
|
---|
284 |
|
---|
285 | <xsl:choose>
|
---|
286 | <xsl:when test="$lang = 'mi'">
|
---|
287 |
|
---|
288 | <gsf:div>
|
---|
289 | Metadata in: Te reo MÄori (or switch to <a href="{$library_name}/collection/{$collName}/document/{$docID}?l=en">English</a>)
|
---|
290 | </gsf:div>
|
---|
291 | <hr />
|
---|
292 |
|
---|
293 | <gsf:script>
|
---|
294 | $(document).ready(function() {
|
---|
295 | displayMetadataDiv("In brief:", ["caption","content"], ["mi_NZ_TEASER_caption", "mi_NZ_TEASER_content"], "tipple-metadata");
|
---|
296 | });
|
---|
297 | </gsf:script>
|
---|
298 |
|
---|
299 | <gsf:metadata hidden="true" name="mi_NZ_TEASER_caption"/>
|
---|
300 | <gsf:metadata hidden="true" name="mi_NZ_TEASER_content"/>
|
---|
301 |
|
---|
302 | <gsf:script>
|
---|
303 | $(document).ready(function() {
|
---|
304 | displayMetadataDiv("In more detail:", ["caption","content"], ["mi_NZ_DESCRIPTION_caption", "mi_NZ_DESCRIPTION_content"], "tipple-metadata");
|
---|
305 | });
|
---|
306 | </gsf:script>
|
---|
307 |
|
---|
308 | <gsf:metadata hidden="true" name="mi_NZ_DESCRIPTION_caption"/>
|
---|
309 | <gsf:metadata hidden="true" name="mi_NZ_DESCRIPTION_content"/>
|
---|
310 |
|
---|
311 | </xsl:when>
|
---|
312 | <xsl:otherwise>
|
---|
313 | <gsf:div>
|
---|
314 | Metadata in : English (or switch to <a href="{$library_name}/collection/{$collName}/document/{$docID}?l=mi">Te Reo MÄori</a>)
|
---|
315 | </gsf:div>
|
---|
316 | <hr />
|
---|
317 |
|
---|
318 | <gsf:script>
|
---|
319 | $(document).ready(function() {
|
---|
320 | displayMetadataDiv("In brief:", ["caption","content"], ["en_TEASER_caption", "en_TEASER_content"], "tipple-metadata");
|
---|
321 | });
|
---|
322 | </gsf:script>
|
---|
323 |
|
---|
324 | <gsf:metadata hidden="true" name="en_TEASER_caption"/>
|
---|
325 | <gsf:metadata hidden="true" name="en_TEASER_content"/>
|
---|
326 |
|
---|
327 | <gsf:script>
|
---|
328 | $(document).ready(function() {
|
---|
329 | displayMetadataDiv("In more detail:", ["caption","content"], ["en_DESCRIPTION_caption", "en_DESCRIPTION_content"], "tipple-metadata");
|
---|
330 | });
|
---|
331 | </gsf:script>
|
---|
332 | <gsf:metadata hidden="true" name="en_DESCRIPTION_caption"/>
|
---|
333 | <gsf:metadata hidden="true" name="en_DESCRIPTION_content"/>
|
---|
334 | </xsl:otherwise>
|
---|
335 | </xsl:choose>
|
---|
336 | <gsf:div id="tipple-metadata"/>
|
---|
337 | </gsf:when>
|
---|
338 | </gsf:switch>
|
---|
339 |
|
---|
340 | <gsf:div id="tipple-assocfiles"/>
|
---|
341 | <gsf:metadata hidden="true" name="contentType"/>
|
---|
342 | <gsf:metadata hidden="true" name="sourceUri"/>
|
---|
343 |
|
---|
344 | <gsf:script>
|
---|
345 | $(document).ready(function() {
|
---|
346 | displayAssocfilesDiv("Media elements:", "tipple-assocfiles");
|
---|
347 | });
|
---|
348 | </gsf:script>
|
---|
349 |
|
---|
350 | <!--
|
---|
351 | <xsl:call-template name="wrappedSectionImage"/>
|
---|
352 | -->
|
---|
353 | <div id="gs-document-text" style="font-size: 75%; line-height: 120%; display: none;">
|
---|
354 | <xsl:call-template name="documentNodeText"/>
|
---|
355 | </div>
|
---|
356 | </div>
|
---|
357 |
|
---|
358 |
|
---|
359 | <xsl:call-template name="documentPost"/>
|
---|
360 |
|
---|
361 | </gsf:template>
|
---|
362 |
|
---|
363 |
|
---|
364 | <!--
|
---|
365 | Overwriting this template can be used to change the content of section headings.
|
---|
366 | -->
|
---|
367 | <!--
|
---|
368 | <gsf:template name="sectionHeading">
|
---|
369 | <xsl:call-template name="choose-title"/>
|
---|
370 | </gsf:template>
|
---|
371 | -->
|
---|
372 |
|
---|
373 | <!--
|
---|
374 | Overwriting this template can be used to change the content of the top-level section.
|
---|
375 | -->
|
---|
376 | <!--
|
---|
377 | <gsf:template name="topLevelSectionContent">
|
---|
378 | <xsl:call-template name="wrappedSectionImage"/>
|
---|
379 | <xsl:call-template name="wrappedSectionText"/>
|
---|
380 | </gsf:template>
|
---|
381 | -->
|
---|
382 |
|
---|
383 | <!--
|
---|
384 | Overwriting this template can be used to change the content of sections.
|
---|
385 | -->
|
---|
386 | <!--
|
---|
387 | <gsf:template name="sectionContent">
|
---|
388 | <xsl:call-template name="wrappedSectionImage"/>
|
---|
389 | <xsl:call-template name="wrappedSectionText"/>
|
---|
390 | </gsf:template>
|
---|
391 | -->
|
---|
392 | </format>
|
---|
393 | </display>
|
---|
394 | <replaceListRef id="gs2-standard"/>
|
---|
395 | <replaceListRef id="gs2-image" />
|
---|
396 | <serviceRackList>
|
---|
397 | <!-- comment out the following serviceRack if you want to disable RSS for this collection -->
|
---|
398 | <serviceRack name="RSSRetrieve"/>
|
---|
399 | <!-- comment out the following serviceRack if you want to disable OAI for this collection -->
|
---|
400 | <serviceRack name="OAIPMH">
|
---|
401 | <setName>tipple-waiata</setName>
|
---|
402 | <setDescription></setDescription>
|
---|
403 | <!-- uncomment the following and set the name attribute if
|
---|
404 | you want this collection to be part of a super set. -->
|
---|
405 | <!--<oaiSuperSet name="xxx"/>-->
|
---|
406 | <ListMetadataFormats>
|
---|
407 | <!--What metadata sets to support for this collection. You can select any set that is specified in OAIConfig.xml. To use a new set, you need to add a set definition in OAIConfig.xml, then reference it here, like:
|
---|
408 | <metadataFormat metadataPrefix="prefix"/> -->
|
---|
409 |
|
---|
410 | <metadataFormat metadataPrefix="oai_dc">
|
---|
411 | <!-- you can customize the mappings by adding elements in here. See resources/oai/OAIConfig.xml for the format-->
|
---|
412 | </metadataFormat>
|
---|
413 | </ListMetadataFormats>
|
---|
414 | </serviceRack>
|
---|
415 | </serviceRackList>
|
---|
416 | </CollectionConfig>
|
---|