source: documented-examples/trunk/lomdemo-e/etc/collectionConfig.xml@ 36611

Last change on this file since 36611 was 36611, checked in by kjdon, 19 months ago

loms custom macro replacements can go into its own collectionConfig.xml

File size: 11.1 KB
Line 
1<?xml version="1.0" encoding="UTF-8"?>
2<CollectionConfig xmlns:gsf="http://www.greenstone.org/greenstone3/schema/ConfigFormat" xmlns:gslib="http://www.greenstone.org/skinning" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3 <metadataList>
4 <metadata lang="en" name="creator">[email protected]</metadata>
5 <metadata lang="en" name="maintainer"/>
6 <metadata lang="en" name="public">true</metadata>
7 </metadataList>
8 <displayItemList>
9 <displayItem assigned="true" dictionary="collectionConfig" key="name" name="name"/>
10 <displayItem assigned="true" lang="en" name="name">LOM Demonstration</displayItem>
11 <displayItem assigned="true" dictionary="collectionConfig" key="shortDescription" name="shortDescription"/>
12 <displayItem assigned="true" dictionary="collectionConfig" key="description1" name="description1"/>
13 <displayItem assigned="true" dictionary="collectionConfig" key="description2" name="description2"/>
14 <displayItem assigned="true" dictionary="collectionConfig" key="description3" name="description3"/>
15 <displayItem assigned="true" dictionary="collectionConfig" key="description4" name="description4"/>
16 <displayItem assigned="true" dictionary="collectionConfig" key="description5" name="description5"/>
17 <displayItem assigned="true" dictionary="collectionConfig" key="as" name="as"/>
18 <displayItem assigned="true" dictionary="collectionConfig" key="sc" name="sc"/>
19 <displayItem assigned="true" dictionary="collectionConfig" key="ar" name="ar"/>
20 <displayItem assigned="true" dictionary="collectionConfig" key=".general^title" name=".general^title"/>
21 <displayItem assigned="true" dictionary="collectionConfig" key=".general^description" name=".general^description"/>
22 <displayItem assigned="true" dictionary="collectionConfig" key=".text,rawtext" name=".text,rawtext"/>
23 <displayItem assigned="true" dictionary="collectionConfig" key=".general^keyword" name=".general^keyword"/>
24 </displayItemList>
25 <format> <xsl:template name="additionalHeaderContent">
26 <xsl:variable name="httpCollection">
27 <xsl:value-of select="/page/pageResponse/collection/metadataList/metadata[@name='httpPath']"/>
28 </xsl:variable>
29 <link href="{$httpCollection}/style/lom-style.css" rel="stylesheet" type="text/css"/>
30 <script src="{$httpCollection}/script/lomscript.js" type="text/javascript"> </script> </xsl:template>
31
32</format>
33 <search type="mgpp">
34 <level name="document"/>
35 <defaultLevel name="document"/>
36 <index name="general^keyword">
37 <displayItem assigned="true" dictionary="collectionConfig" key="general^keyword" name="name"/>
38 </index>
39 <index name="general^title">
40 <displayItem assigned="true" dictionary="collectionConfig" key="general^title" name="name"/>
41 </index>
42 <index name="text,rawtext">
43 <displayItem assigned="true" dictionary="collectionConfig" key="text_and_rawtext" name="name"/>
44 </index>
45 <index name="general^description">
46 <displayItem assigned="true" dictionary="collectionConfig" key="general^description" name="name"/>
47 </index>
48 <defaultIndex name="text"/>
49 <indexOption name="accentfold"/>
50 <indexOption name="casefold"/>
51 <indexOption name="stem"/>
52 <indexSubcollection name="arts,science">
53 <displayItem lang="en" name="name">arts,science</displayItem>
54 </indexSubcollection>
55 <indexSubcollection name="arts">
56 <displayItem lang="en" name="name">arts</displayItem>
57 </indexSubcollection>
58 <indexSubcollection name="science">
59 <displayItem lang="en" name="name">science</displayItem>
60 </indexSubcollection>
61 <subcollection filter="dc.Subject/Science" name="science"/>
62 <subcollection filter="dc.Subject/Arts" name="arts"/>
63 <searchType name="plain"/>
64 <searchType name="simpleform"/>
65 <searchType name="advancedform"/>
66 <format>
67 <gsf:template match="documentNode">
68 <gsf:format-gs2><![CDATA[
69<td>[link][icon][/link]
70</td>
71<td>{If}{[numleafdocs],([numleafdocs])}
72</td>
73<td>{OR}{[general^title],[Title]}
74</td>]]></gsf:format-gs2>
75 <td>
76 <gsf:link type="document">
77 <gsf:icon type="document"/>
78 </gsf:link>
79 </td>
80 <td/>
81 <td>
82 <gsf:choose-metadata>
83 <gsf:metadata name="general^title"/>
84 <gsf:metadata name="Title"/>
85 </gsf:choose-metadata>
86 </td>
87 </gsf:template>
88 </format>
89 </search>
90 <infodb type="gdbm"/>
91 <import>
92 <pluginList>
93 <plugin name="GreenstoneXMLPlugin"/>
94 <plugin name="LOMPlugin">
95 <option name="-download_srcdocs" value="(?i)\\.(html?|jpe?g|gif)$"/>
96 </plugin>
97 <plugin name="HTMLPlugin"/>
98 <plugin name="ImagePlugin"/>
99 <plugin name="PDFPlugin"/>
100 <plugin name="WordPlugin"/>
101 <plugin name="MetadataXMLPlugin"/>
102 <plugin name="ArchivesInfPlugin"/>
103 <plugin name="DirectoryPlugin"/>
104 </pluginList>
105 </import>
106 <browse>
107 <classifier name="List">
108 <option name="-metadata" value="dc.Subject/ex.general^title;Title"/>
109 <option name="-removesuffix" value="(\\s*(\\/|\\(|\\)|\\,|\\:|\\;|\\-).*)|\\s+"/>
110 <option name="-buttonname" value="Subject"/>
111 <option name="-partition_type_within_level" value="none"/>
112 </classifier>
113 <classifier name="DateList">
114 <option name="-metadata" value="lifecycle^contribute^date"/>
115 <option name="-buttonname" value="Date"/>
116 <option name="-sort" value="general^title"/>
117 <format>
118 <gsf:template match="documentNode">
119 <gsf:format-gs2><![CDATA[<td>[link][icon][/link]</td><td>[general^title]</td>]]></gsf:format-gs2>
120 <td>
121 <gsf:link type="document">
122 <gsf:icon type="document"/>
123 </gsf:link>
124 </td>
125 <td>
126 <gsf:metadata name="general^title"/>
127 </td>
128 </gsf:template>
129 </format>
130 </classifier>
131 <format>
132 <gsf:template match="documentNode">
133 <gsf:format-gs2><![CDATA[
134<td>[link][icon][/link]
135</td>
136<td>{If}{[numleafdocs],([numleafdocs])}
137</td>
138<td>{OR}{[general^title],[Title]}
139</td>]]></gsf:format-gs2>
140 <td>
141 <gsf:link type="document">
142 <gsf:icon type="document"/>
143 </gsf:link>
144 </td>
145 <td/>
146 <td>
147 <gsf:choose-metadata>
148 <gsf:metadata name="general^title"/>
149 <gsf:metadata name="Title"/>
150 </gsf:choose-metadata>
151 </td>
152 </gsf:template>
153 <gsf:template match="classifierNode">
154 <gsf:format-gs2><![CDATA[
155<td>[link][icon][/link]
156</td>
157<td>{If}{[numleafdocs],([numleafdocs])}
158</td>
159<td>{OR}{[general^title],[Title]}
160</td>]]></gsf:format-gs2>
161 <td>
162 <gsf:link type="classifier">
163 <gsf:icon type="classifier"/>
164 </gsf:link>
165 </td>
166 <td>(<gsf:metadata name="numleafdocs"/>)</td>
167 <td>
168 <gsf:choose-metadata>
169 <gsf:metadata name="general^title"/>
170 <gsf:metadata name="Title"/>
171 </gsf:choose-metadata>
172 </td>
173 </gsf:template>
174 <gsf:template match="classifierNode" mode="horizontal">
175 <gsf:format-gs2><![CDATA[[link][highlight]{Or}{[dls.Title],[dc.Title],[ex.Title],Untitled}[/highlight][/link]]]></gsf:format-gs2>
176 <gsf:link type="classifier">
177 <span class="highlight">
178 <gsf:choose-metadata><gsf:metadata name="dls.Title"/><gsf:metadata name="dc.Title"/><gsf:metadata name="Title"/>Untitled</gsf:choose-metadata>
179 </span>
180 </gsf:link>
181 </gsf:template>
182 </format>
183 </browse>
184 <display>
185 <format> <gsf:option name="TOC" value="true"/>
186 <gsf:option name="AllowUserComments" value="false"/>
187 <gsf:template name="documentContent">
188 <div id="gs-document">
189 <xsl:call-template name="documentPre"/>
190 <xsl:call-template name="wrappedSectionImage"/>
191 <div id="gs-document-text">
192 <p>
193 <center>
194 <table class="lom">
195 <tr>
196 <td class="mdtabdip"> </td>
197 <td class="mdhreftab mdtabtabbg">
198 <a class="mdtablink" href="javascript:doShowHide('metatablediv', 'xmlrecordarea');">Metadata</a>
199 </td>
200 <td class="mdtabdip"> </td>
201 <td class="mdtexttab mdtabtabbg">
202 <a class="mdtablink" href="javascript:doShowHide('xmlrecordarea', 'metatablediv');">XML record</a>
203 </td>
204 <gsf:switch>
205 <gsf:metadata name="Plugin"/>
206 <gsf:when test="notEquals" test-value="LOMPlugin">
207 <td class="mdtabdip"> </td>
208 <td class="mdhreftab">
209 <a class="mdtablink" href="javascript:;">Document</a>
210 </td>
211 </gsf:when>
212 <gsf:otherwise>
213 <td class="mdtabdip"> </td>
214 <td class="mdtabblank"> </td>
215 <td class="mdtabdip"> </td>
216 </gsf:otherwise>
217 </gsf:switch>
218 <td class="mdtabfill"> </td>
219 </tr>
220 </table>
221 <textarea cols="80" id="xmlrecordarea" rows="25" style="display:none"><gsf:switch><gsf:metadata name="Plugin"/><gsf:when test="equals" test-value="LOMPlugin"><xsl:value-of disable-output-escaping="yes" select="nodeContent"/></gsf:when><gsf:otherwise><gsf:metadata name="rawtext"/></gsf:otherwise></gsf:switch> </textarea>
222 <div id="metatablediv">
223 <gsf:metadata name="MetadataTable"/>
224 </div>
225 </center>
226 </p>
227<!--
228<xsl:call-template name="documentNodeText"/>
229-->
230 </div>
231 </div>
232 </gsf:template>
233<!--
234Overwriting this template allows you to change the heading of the document.
235-->
236<!--
237<gsf:template name="documentHeading">
238<span style="font-weight:bold; font-size: 120%;">
239<xsl:call-template name="choose-title"/>
240</span>
241</gsf:template>
242-->
243<!--
244Overwriting this template can be used to redefine the content of the whole document.This is useful for simple documents, but not recommended for more complex documents(e.g. hierachical and paged documents) as it can prevent any sub-sections from showing.
245-->
246<!--
247<gsf:template name="documentContent">
248<div id="gs-document">
249<xsl:call-template name="documentPre"/>
250<xsl:call-template name="wrappedSectionImage"/>
251<div id="gs-document-text">
252<xsl:call-template name="documentNodeText"/>
253</div>
254</div>
255</gsf:template>
256-->
257<!--
258Overwriting this template can be used to change the content of section headings.
259-->
260<!--
261<gsf:template name="sectionHeading">
262<xsl:call-template name="choose-title"/>
263</gsf:template>
264-->
265<!--
266Overwriting this template can be used to change the content of the top-level section.
267-->
268<!--
269<gsf:template name="topLevelSectionContent">
270<xsl:call-template name="wrappedSectionImage"/>
271<xsl:call-template name="wrappedSectionText"/>
272</gsf:template>
273-->
274<!--
275Overwriting this template can be used to change the content of sections.
276-->
277<!--
278<gsf:template name="sectionContent">
279<xsl:call-template name="wrappedSectionImage"/>
280<xsl:call-template name="wrappedSectionText"/>
281</gsf:template>
282-->
283
284</format>
285 </display>
286 <replaceListRef id="gs2-standard"/>
287 <replaceListRef id="gs2-image"/>
288 <!-- some custom macro replacements -->
289 <replaceList>
290 <replace macro="_httpopenmdicon_" scope="metadata" text="_httpsite_/collect/_clustername_/images/open.gif&quot; data-img-path=&quot;_httpsite_/collect/_clustername_/images/" resolve="true"/>
291 <replace macro="_httpclosemdicon_" scope="metadata" text="_httpsite_/collect/_clustername_/images/close.gif&quot; data-img-path=&quot;_httpsite_/collect/_clustername_/images/" resolve="true"/>
292 </replaceList>
293
294</CollectionConfig>
Note: See TracBrowser for help on using the repository browser.