en:user:gs3_list_of_format_options
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| en:user:gs3_list_of_format_options [2019/10/21 21:15] – kjdon | en:user:gs3_list_of_format_options [2026/04/29 00:42] (current) – [Options] kjdon | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | |||
| + | |||
| + | |||
| ====== List of Greenstone3 Format Items ====== | ====== List of Greenstone3 Format Items ====== | ||
| Line 23: | Line 26: | ||
| ^Option name^Values^Format^Description^ | ^Option name^Values^Format^Description^ | ||
| | |||| | | |||| | ||
| - | |hideStatus|true|search|If set to true, will hide the line ' | + | |allowGLIEditing|false|top level|If set to true (or absent), allows editing |
| |[[rss|RSS]]|true| |If set to true, will add a RSS Feed link to the collection| | |[[rss|RSS]]|true| |If set to true, will add a RSS Feed link to the collection| | ||
| + | |hideStatus|true|search|If set to true, will hide the line ' | ||
| |turnstyleClassifiers|false|browse|By default, bookshelves display a plus icon to open up that section of the classifier in place. < | |turnstyleClassifiers|false|browse|By default, bookshelves display a plus icon to open up that section of the classifier in place. < | ||
| |mapEnabled|true|display, | |mapEnabled|true|display, | ||
| Line 33: | Line 37: | ||
| |backToTopLinks| |display|?| | |backToTopLinks| |display|?| | ||
| |sideBar|false |display|If false will not display any of the right side bar features, including cover image, search term highlighting checkbox, table of contents etc | | |sideBar|false |display|If false will not display any of the right side bar features, including cover image, search term highlighting checkbox, table of contents etc | | ||
| + | |documentType|simple, | ||
| |disableZoom|true|display| | | |disableZoom|true|display| | | ||
| |disableSearchTermHighlighting|true|display|If set to true, will not highlight search terms in the text, and will not display the on/off button for highlighting| | |disableSearchTermHighlighting|true|display|If set to true, will not highlight search terms in the text, and will not display the on/off button for highlighting| | ||
| Line 56: | Line 61: | ||
| To see what parameters you have that you can change, you can look at the page source for a query page and see what names and values the form elements have. | To see what parameters you have that you can change, you can look at the page source for a query page and see what names and values the form elements have. | ||
| - | These can be added inside the < | + | These can be added inside the < |
| ==== Templates ==== | ==== Templates ==== | ||
| Line 63: | Line 68: | ||
| ''< | ''< | ||
| + | ==== Other ==== | ||
| + | |||
| + | The '' | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | </ | ||
| + | </ | ||
| + | This will output META tags for any of these metadata elements present for the document, like: | ||
| + | < | ||
| + | <META CONTENT=" | ||
| + | </ | ||
| + | | ||
| + | To change the NAME attribute, use the '' | ||
| + | |||
| + | < | ||
| + | < | ||
| + | < | ||
| + | </ | ||
| + | </ | ||
| + | Will output | ||
| + | < | ||
| + | <META CONTENT=" | ||
| + | </ | ||
| + | |||
| + | < | ||
| ===== What can go inside a template? ===== | ===== What can go inside a template? ===== | ||
| ==== Links ==== | ==== Links ==== | ||
| Line 150: | Line 184: | ||
| |format|formatDate|turns ' | |format|formatDate|turns ' | ||
| |::: | |::: | ||
| + | |||
| + | === Table of Metadata === | ||
| + | |||
| + | Sometimes you want a table of metadata values. You can use < | ||
| + | A list of metadata elements, each containing the label that should be used for the metadata. | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | < | ||
| + | </ | ||
| + | |||
| + | </ | ||
| + | |||
| === Hidden metadata === | === Hidden metadata === | ||
| Line 157: | Line 206: | ||
| |hidden|true|If true, then the metadata will be retrieved from the server, but not displayed at that point. | | |hidden|true|If true, then the metadata will be retrieved from the server, but not displayed at that point. | | ||
| + | |||
| + | ==== Collection/ | ||
| + | |||
| + | These will be displayed in the current interface language (if available), otherwise in the default language. | ||
| + | |||
| + | ^Format Element^Greenstone2 equivalent^Description^ | ||
| + | | ||| | ||
| + | |''< | ||
| + | |''< | ||
| + | |''< | ||
| + | |''< | ||
| + | |''< | ||
| + | |''< | ||
| ==== Miscellaneous Things ==== | ==== Miscellaneous Things ==== | ||
| Line 162: | Line 224: | ||
| | ||| | | ||| | ||
| |''< | |''< | ||
| - | |''< | ||
| - | |''< | ||
| - | |''< | ||
| - | |''< | ||
| - | |''< | ||
| |''< | |''< | ||
| + | |''< | ||
| + | |||
| ==== Conditional ==== | ==== Conditional ==== | ||
| Line 241: | Line 300: | ||
| |lang|language code|Defines the language whose sorting conventions are to be used| | |lang|language code|Defines the language whose sorting conventions are to be used| | ||
| |data-type|text/ | |data-type|text/ | ||
| + | |||
| + | ==== Utility Functions ==== | ||
| + | |||
| + | There are many utility functions defined in src/ | ||
| + | |||
| + | They can be called explicitly using | ||
| + | < | ||
| + | < | ||
| + | </ | ||
| + | args is a comma separated list of args. They can be XSLT variables, numbers, strings, XSLT elements/ | ||
| + | |||
| + | For example: | ||
| + | < | ||
| + | < | ||
| + | The collection was last built on < | ||
| + | </ | ||
| + | |||
| + | This code is getting the buildDate timestamp from collection metadata. Then it is formatting it using the formatTimeStamp function. | ||
| + | This function takes 4 arguments: | ||
| + | * the timestamp - here we use the raw_date variable we have just made | ||
| + | * an integer for timestamp type - 0 is seconds, 1 is milliseconds | ||
| + | * an integer for output format tupe - 0 is date, 1 is time, 2 is date and time, 3 is days ago | ||
| + | * the language code for which language you want the output in - here we use the attribute from the page element. | ||
| + | |||
| + | We could change this output to days ago: | ||
| + | The collection was last built < | ||
| ==== Additional Notes ==== | ==== Additional Notes ==== | ||
| + | |||
| Some of these options (< | Some of these options (< | ||
en/user/gs3_list_of_format_options.1571692517.txt.gz · Last modified: 2019/10/21 21:15 (external edit)
