Jump to content
Wiki Home
EPrints Home
Bazaar
Files
Main menu
Main menu
move to sidebar
hide
Navigation
Front Page
EPrints 3 Manual
EPrints Training Course
EPrints Glossary
Installing EPrints
How-to Configure EPrints
EPrints 3.2+ API
EPrints 3 Reference
EPrints Plugins
Wiki
All categories
Recent changes
Main Page
Help
EPrints Documentation
Search
Search
Appearance
Log in
Request account
Personal tools
Log in
Request account
Pages for logged out editors
learn more
Contributions
Talk
Editing
Translation
(section)
Page
Discussion
British English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Phrases == Phrase definitions are scattered in several places. There are repository independent ones and repository dependent ones. The latter has preference over the former: if the same entity is defined in both places then the repository dependent definition takes precedence. Phrases are parsed and stored during web server initialization for all repositories. If you make any change in any of the phrase files, you ''must restart'' the apache server to see the effect. System-wide (i.e. repository independent) phrases are contained in the files in [[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension ".xml" are scanned and read in in alphabetical order. You can split the data into several files instead having a single a huge phrase file. All phrase files must have proper XML syntax. Use existing files as templates. The very first line tells you which encoding is applied in the file: <?xml version="1.0" encoding="iso-8859-1" standalone="no" ?> If no encoding is given, then utf-8 is assumed (and you get error messages if the actual encoding is not that one). Set the encoding into your favourite one. Don't forget that when using iso-8859-X then you can enter a limited set of characters only. <div style="padding: 1em; border: 1px solid #6f2f2f; color: black; background-color: #ffe0e0;"> Due to a bug in GDOME, when you use GDOME, all XML files must be utf-8 encoded (see tech list [http://www.eprints.org/tech.php/7295.html 7295]). </div> You can define as many new phrases as you want, and refer them in other phrases. During initialization all phrases are stored, and expanded only when used. If a phrase has several definitions, the one which has been read in last will be used. This means that you can have forward references; and this mechanism ensures that system-wide phrases are redefined by entries in a repository-dependent phrase file. <div style="font-size:small;">CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.</div> Phrases are defined as follows: <epp:phrase id="lib/dataset:no_language">Unknown/Other</epp:phrase> This line defined the "<code>lib/dataset:no_language</code>" phrase to be equal to "<code>Unknown/Other</code>". A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases: <epp:phrase id=double_ruler> <epc:phrase ref="ruler"/><epc:phrase ref="ruler"/> </epp:phrase> Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name <epp:phrase id="doc_title">Document: <epc:pin name="doc" /></epp:phrase> or a URL (pins typically called "link") where the link text comes between "<code><epc:pin name=...></code>" and "<code></epc:pin></code>": <epp:phrase id="show_help"><epc:pin name="link"> <img src="/images/help.gif" alt="+"></epc:pin></epp:phrase> If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the "<code>show_help</code>" phrase in another one, you must supply the pin. It is done through "<code>epc:param</code>" tags. The pin in this case is an "<code><a /></code>" tag which defines the URL of the help text: <epp:phrase id="use_help">Help using the show_help phrase: <epc:phrase ref="show_help"> <nowiki><epc:param name="link"><a href="http://..." /></epc:param></nowiki> </epc:phrase> </epp:phrase> You can use other [[EPrints_Control_Format|control format]] elements as well.
Summary:
Please note that all contributions to EPrints Documentation may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
EPrints Documentation:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)