<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>https://wiki.eprints.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Csirmaz</id>
	<title>EPrints Documentation - User contributions [en-gb]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.eprints.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Csirmaz"/>
	<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/Special:Contributions/Csirmaz"/>
	<updated>2026-05-07T21:22:28Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.31.8</generator>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=User:Csirmaz&amp;diff=4599</id>
		<title>User:Csirmaz</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=User:Csirmaz&amp;diff=4599"/>
		<updated>2007-07-09T08:39:18Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== László Csirmaz ==&lt;br /&gt;
&lt;br /&gt;
A mathematician by education, Head of [http://www.ceu.hu/comp  Computer and Statistics Center] of the [http://www.ceu.hu  Central European University], [http://www.fsz.bme.hu/hungary/budapest/budapest.html Budapest].&lt;br /&gt;
Teaching Mathematical Logic at [http://www.cs.elte.hu| Eötvös Lorand University],&lt;br /&gt;
Theoretical Cryptography at [http://www.inf.unideb.hu University of Debrecen]. Check the web page at http://www.renyi.hu/~csirmaz/ for more info.&lt;br /&gt;
&lt;br /&gt;
When asked to overlook the implementation of the [http://pdc.ceu.hu  Policy Documentation Center], I have been fascianted by the clear programming style&lt;br /&gt;
and high usability of the EPrints software. (&amp;quot;Just the way such a thing should be done!&amp;quot;) Since then ocassionally I throw in my 2 pence worth hoping that it migh be useful for the EPrints community.&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4595</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4595"/>
		<updated>2007-07-06T12:24:51Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Pluralising depends on language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the &amp;quot;&amp;lt;code&amp;gt;show_help&amp;lt;/code&amp;gt;&amp;quot; phrase in another one, you must supply the pin. It is done through &amp;quot;&amp;lt;code&amp;gt;epc:param&amp;lt;/code&amp;gt;&amp;quot; tags. The pin in this case is an &amp;quot;&amp;lt;code&amp;gt;&amp;lt;a /&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; tag which defines the URL of the help text:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;use_help&amp;quot;&amp;gt;Help using the show_help phrase: &lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;show_help&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;nowiki&amp;gt;&amp;lt;epc:param name=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;http://...&amp;quot; /&amp;gt;&amp;lt;/epc:param&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use other [[EPrints_Control_Format|control format]] elements as well.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095], [http://www.eprints.org/tech.php/7157.html 7157] and [http://www.eprints.org/tech.php/7300.html 7300].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You might consider applying some of the [[#Patches|patches]].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Pluralising depends on language|pluralising depens on language]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Pluralising depends on language ===&lt;br /&gt;
&lt;br /&gt;
When invoking a phrase in a citation, the Escript constucts such as &amp;lt;code&amp;gt;&amp;lt;epc:if test=&amp;quot;...&amp;quot; /&amp;gt;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;lt;epc print /&amp;gt;&amp;lt;/code&amp;gt; are not available any more. To transfer pluralising from the citation file into phrases file requires this feature which is achieved by the [[XML/EPC.pm.diff.2]] patch. See tech list [[http://www.eprints.org/tech.php/7300.html 7300]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4594</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4594"/>
		<updated>2007-07-06T12:17:31Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Pluralising depends on language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the &amp;quot;&amp;lt;code&amp;gt;show_help&amp;lt;/code&amp;gt;&amp;quot; phrase in another one, you must supply the pin. It is done through &amp;quot;&amp;lt;code&amp;gt;epc:param&amp;lt;/code&amp;gt;&amp;quot; tags. The pin in this case is an &amp;quot;&amp;lt;code&amp;gt;&amp;lt;a /&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; tag which defines the URL of the help text:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;use_help&amp;quot;&amp;gt;Help using the show_help phrase: &lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;show_help&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;nowiki&amp;gt;&amp;lt;epc:param name=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;http://...&amp;quot; /&amp;gt;&amp;lt;/epc:param&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use other [[EPrints_Control_Format|control format]] elements as well.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095], [http://www.eprints.org/tech.php/7157.html 7157] and [http://www.eprints.org/tech.php/7300.html 7300].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You might consider applying some of the [[#Patches|patches]].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Pluralising depends on language|pluralising depens on language]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Pluralising depends on language ===&lt;br /&gt;
&lt;br /&gt;
When invoking a phrase in a citation, the Escript constucts such as &amp;lt;code&amp;gt;&amp;lt;epc:if test=&amp;quot;...&amp;quot; /&amp;gt;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;lt;epc print /&amp;gt;&amp;lt;/code&amp;gt; are not available any more. To transfer pluralising from the citation file into phrases file the [[XML/EPC.pm.diff.2]] patch is necessary. See tech list [[http://www.eprints.org/tech.php/7300.html 7300]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4592</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4592"/>
		<updated>2007-07-06T12:12:32Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Other configuration files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the &amp;quot;&amp;lt;code&amp;gt;show_help&amp;lt;/code&amp;gt;&amp;quot; phrase in another one, you must supply the pin. It is done through &amp;quot;&amp;lt;code&amp;gt;epc:param&amp;lt;/code&amp;gt;&amp;quot; tags. The pin in this case is an &amp;quot;&amp;lt;code&amp;gt;&amp;lt;a /&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; tag which defines the URL of the help text:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;use_help&amp;quot;&amp;gt;Help using the show_help phrase: &lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;show_help&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;nowiki&amp;gt;&amp;lt;epc:param name=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;http://...&amp;quot; /&amp;gt;&amp;lt;/epc:param&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use other [[EPrints_Control_Format|control format]] elements as well.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095], [http://www.eprints.org/tech.php/7157.html 7157] and [http://www.eprints.org/tech.php/7300.html 7300].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You might consider applying some of the [[#Patches|patches]].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Pluralising depends on language|pluralising depens on language]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Pluralising depends on language ===&lt;br /&gt;
&lt;br /&gt;
When invoking a phrase in a citation, the Escript constucts such as &amp;lt;code&amp;gt;&amp;lt;epc:if test=&amp;quot;...&amp;quot; /&amp;gt;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;lt;epc print /&amp;gt;&amp;lt;/code&amp;gt; are not availble any more. To transfer pluralising from the citation file into phrases file the [[XML/EPC.pm.diff.2]] patch is necessary. See tech list [[http://www.eprints.org/tech.php/7300.html 7300]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4591</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4591"/>
		<updated>2007-07-06T12:09:30Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Patches */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the &amp;quot;&amp;lt;code&amp;gt;show_help&amp;lt;/code&amp;gt;&amp;quot; phrase in another one, you must supply the pin. It is done through &amp;quot;&amp;lt;code&amp;gt;epc:param&amp;lt;/code&amp;gt;&amp;quot; tags. The pin in this case is an &amp;quot;&amp;lt;code&amp;gt;&amp;lt;a /&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; tag which defines the URL of the help text:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;use_help&amp;quot;&amp;gt;Help using the show_help phrase: &lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;show_help&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;nowiki&amp;gt;&amp;lt;epc:param name=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;http://...&amp;quot; /&amp;gt;&amp;lt;/epc:param&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use other [[EPrints_Control_Format|control format]] elements as well.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Pluralising depends on language|pluralising depens on language]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Pluralising depends on language ===&lt;br /&gt;
&lt;br /&gt;
When invoking a phrase in a citation, the Escript constucts such as &amp;lt;code&amp;gt;&amp;lt;epc:if test=&amp;quot;...&amp;quot; /&amp;gt;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;lt;epc print /&amp;gt;&amp;lt;/code&amp;gt; are not availble any more. To transfer pluralising from the citation file into phrases file the [[XML/EPC.pm.diff.2]] patch is necessary. See tech list [[http://www.eprints.org/tech.php/7300.html 7300]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4590</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4590"/>
		<updated>2007-07-06T09:15:51Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins. Thus if you use the &amp;quot;&amp;lt;code&amp;gt;show_help&amp;lt;/code&amp;gt;&amp;quot; phrase in another one, you must supply the pin. It is done through &amp;quot;&amp;lt;code&amp;gt;epc:param&amp;lt;/code&amp;gt;&amp;quot; tags. The pin in this case is an &amp;quot;&amp;lt;code&amp;gt;&amp;lt;a /&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; tag which defines the URL of the help text:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;use_help&amp;quot;&amp;gt;Help using the show_help phrase: &lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;show_help&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;nowiki&amp;gt;&amp;lt;epc:param name=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;a href=&amp;quot;http://...&amp;quot; /&amp;gt;&amp;lt;/epc:param&amp;gt;&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use other [[EPrints_Control_Format|control format]] elements as well.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4589</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4589"/>
		<updated>2007-07-05T15:39:11Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you get an ugly error message about undefined pins.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4588</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4588"/>
		<updated>2007-07-05T15:38:23Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px solid #6f2f2f;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #ffe0e0;&amp;quot;&amp;gt;&lt;br /&gt;
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]).&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Phrases are defined as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;lib/dataset:no_language&amp;quot;&amp;gt;Unknown/Other&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This line defined the &amp;quot;&amp;lt;code&amp;gt;lib/dataset:no_language&amp;lt;/code&amp;gt;&amp;quot; phrase to be equal to &amp;quot;&amp;lt;code&amp;gt;Unknown/Other&amp;lt;/code&amp;gt;&amp;quot;. A phrase must have a proper XML syntax (i.e. all tags must be balanced). In the definition you can refer to other phrases:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=double_ruler&amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;ruler&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Certain phrases use ''pins''. Pins are typically defined by the calling routine, and carry variable content, such as the document's name&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;doc_title&amp;quot;&amp;gt;Document: &amp;lt;epc:pin name=&amp;quot;doc&amp;quot; /&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
or a URL (pins typically called &amp;quot;link&amp;quot;) where the link text comes between &amp;quot;&amp;lt;code&amp;gt;&amp;lt;epc:pin name=...&amp;gt;&amp;lt;/code&amp;gt;&amp;quot; and &amp;quot;&amp;lt;code&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/code&amp;gt;&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;show_help&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;img src=&amp;quot;/images/help.gif&amp;quot; alt=&amp;quot;+&amp;quot;&amp;gt;&amp;lt;/epc:pin&amp;gt;&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If a phrase requires a pin but none defined, you've got an ungly formatted error message about undefined pins.&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4587</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4587"/>
		<updated>2007-07-05T14:51:50Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Example: the citations/saved_search/default.xml file */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4586</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4586"/>
		<updated>2007-07-05T14:36:37Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting document language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session:&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_document_defaults} = sub&lt;br /&gt;
 {&lt;br /&gt;
        my( $data, $session, $eprint ) = @_;&lt;br /&gt;
  ###### HERE:&lt;br /&gt;
        $data-&amp;gt;{language} = $session-&amp;gt;get_langid();&lt;br /&gt;
        $data-&amp;gt;{security} = &amp;quot;public&amp;quot;;&lt;br /&gt;
 };&lt;br /&gt;
&lt;br /&gt;
The available language values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is rendered as a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4585</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4585"/>
		<updated>2007-07-05T14:32:39Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Rendering user names depending on session language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields.pl]] file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4584</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4584"/>
		<updated>2007-07-05T14:25:40Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Example: the citations/saved_search/default.xml file */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' the search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4583</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4583"/>
		<updated>2007-07-05T14:21:57Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting document language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other')&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' and search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4582</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4582"/>
		<updated>2007-07-05T13:37:22Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Other configuration files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See also the tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' and search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4581</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4581"/>
		<updated>2007-07-05T13:35:08Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Example: the citations/document/default.xml file */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' and search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;, &amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;gt; Xpdf &amp;lt;/a&amp;gt; or &amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;gt; Adobe Acrobat Reader &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a  href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt; GSview &amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Use phrases instead:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_pdf_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;15&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; &amp;lt;epc:phrase&amp;amp;nbsp;ref=&amp;quot;need_postscript_viewer&amp;quot;/&amp;gt; &amp;lt;/epc:when&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;16&amp;lt;/td&amp;gt;&amp;lt;td colspan=&amp;quot;2&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;nowiki&amp;gt;&amp;lt;/epc:choose&amp;gt;&amp;lt;/nowiki&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The appropriate English phrase definitions would run as follows:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;epp:phrase id=&amp;quot;need_pdf_viewer&amp;quot;&amp;gt; - Requires a PDF viewer such as ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
 &amp;lt;epp_phrase id=&amp;quot;need_postscript_viewer&amp;quot;&amp;gt; - Requires a viewer, such ...&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4580</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4580"/>
		<updated>2007-07-05T11:39:35Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Other configuration files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/saved_search/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
In the default EPrints distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
  9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Whenever a saved search is formatted using the default citation style '''and''' and search has no attached name, then the &amp;quot;otherwise&amp;quot; case in line 11 is chosen. It prints ''Untitled search #'' followed by the search internal number. This text should be language dependent and use a phrase. For example the replacement&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11   &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name&amp;quot; /&amp;gt;&lt;br /&gt;
                #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
would do the job. If you want to be more gentle to translators (probably to yourself) then you could rather use a phrase with a ''pin'' for the search number:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
11 &amp;lt;epc:otherwise&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
          &amp;lt;epc:param name=&amp;quot;n&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:param&amp;gt;&lt;br /&gt;
          &amp;lt;/epc:phrase&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In this last case the English definition of the phrase would be&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;epp:phrase id=&amp;quot;saved_search_no_name_with_pin&amp;quot;&amp;gt;&lt;br /&gt;
    Untitled search #&amp;lt;epc:pin name=&amp;quot;n&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold; &amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; &lt;br /&gt;
* Pin definition with an &amp;quot;epc:param&amp;quot; tag works only in citation files.&lt;br /&gt;
* You '''must''' apply the  &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section for this work correctly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example: the citations/document/default.xml file ===&lt;br /&gt;
&lt;br /&gt;
This file describes how documents should be rendered. When the document's type is pdf or postscript, then a helper text appears, which informs the reader that a special viewer program is necessary (long lines are wrapped)&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table width=&amp;quot;100%&amp;quot; cellpadding=&amp;quot;3&amp;quot; style=&amp;quot;padding: 1em;&lt;br /&gt;
    border: 1px dashed #2f6fab;&lt;br /&gt;
    color: black;&lt;br /&gt;
    background-color: #f9f9f9;&lt;br /&gt;
    line-height: 1.1em;&amp;quot; class=&amp;quot;code&amp;quot;&amp;gt;&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;13&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;epc:choose&amp;gt;&amp;lt;/pre&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td valign=&amp;quot;top&amp;quot;&amp;gt;14&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;epc:when test=&amp;quot;format = 'application/pdf'&amp;quot;&amp;gt; - Requires a PDF viewer such as &amp;amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;amp;gt;GSview&amp;amp;lt;/a&amp;amp;gt;, &amp;amp;lt;a href=&amp;quot;http://www.foolabs.com/xpdf/download.html&amp;quot;&amp;amp;gt;Xpdf&amp;amp;lt;/a&amp;amp;gt; or &amp;amp;lt;a href=&amp;quot;http://www.adobe.com/products/acrobat/&amp;quot;&amp;amp;gt;Adobe Acrobat Reader&amp;amp;lt;/a&amp;amp;gt;&amp;lt;/epc:when&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
15   &amp;lt;epc:when test=&amp;quot;format = 'application/postscript'&amp;quot;&amp;gt; - Requires a viewer, such as &amp;lt;a href=&amp;quot;http://www.cs.wisc.edu/~ghost/gsview/index.htm&amp;quot;&amp;gt;GSview&amp;lt;/a&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
&lt;br /&gt;
16 &amp;lt;/epc:choose&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
See tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4579</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4579"/>
		<updated>2007-07-05T09:33:37Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Other configuration files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: &amp;amp;quot;''Untitled search''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: &amp;amp;quot;''Untitled subject''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14 and 15: &amp;amp;quot;''Requires a viewer...''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 37: &amp;amp;quot;''In...ed/eds''&amp;amp;quot;; line 62: &amp;amp;quot;''In''&amp;amp;quot;; line 66: &amp;amp;quot;''thesis''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: &amp;amp;quot;''Item not available''&amp;amp;quot; and &amp;amp;quot;''Item availability restricted''&amp;amp;quot;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: &amp;amp;quot;''ed/eds''&amp;amp;quot;; line 30: &amp;amp;quot;''deposited..''&amp;amp;quot; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;NOTE: the date format is fixed and does not change with the language.&amp;lt;/span&amp;gt;&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_succeeds.xml]] line 10: as above&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|cfg/citations/user/default.xml]] line 11 and 12: &amp;amp;quot;''Unnamed user''&amp;amp;quot; (twice)&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]] lines 83, 248, 259, 268: component titles&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] lines 45, 54: component titles &amp;amp;quot;''Editorial Alerts''&amp;amp;quot;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;hr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In the default distribution the [[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] file contains the following lines:&lt;br /&gt;
&lt;br /&gt;
   9  &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
 10   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
 11   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
 12  &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
See tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4578</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4578"/>
		<updated>2007-07-05T09:08:23Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Other configuration files */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. First the list of these files and places, and then two examples of how they can be handled.&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/saved_search/default.xml]] line 11: ''Untitled search''&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/lib/citations|lib/citations/subject/screen.xml]] line 11: ''Untitle subject''&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] lines 14, 15: ''Require a PDF viewer'', ''Requires a viewer such ...''&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/default.xml]] line 16: ''ed/eds''; line 37: ''In...ed/eds&amp;quot;; line 62: ''In''; line 66: ''thesis''&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/result.xml]] lines 12, 13: ''Item no available'', ''Item availability restricted''&lt;br /&gt;
*[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|cfg/citations/eprint/thread_commentary.xml]] line 18: ''ed/eds''; line 30: ''deposited..'' &amp;lt;span style=&amp;quot;color:red; font-weight: bold;&amp;quot;&amp;gt;NOTE&amp;lt;/span&amp;gt; the date is ''not'' in the current language.&lt;br /&gt;
&lt;br /&gt;
 lib/citations/saved_search/default.xml&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;&amp;lt;epc:choose&amp;gt;&lt;br /&gt;
   &amp;lt;epc:when test=&amp;quot;name&amp;quot;&amp;gt;&amp;lt;epc:print expr=&amp;quot;name&amp;quot;/&amp;gt;&amp;lt;/epc:when&amp;gt;&lt;br /&gt;
   &amp;lt;epc:otherwise&amp;gt;Untitled search #&amp;lt;epc:print expr=&amp;quot;id&amp;quot;/&amp;gt;&amp;lt;/epc:otherwise&amp;gt;&lt;br /&gt;
 &amp;lt;/epc:choose&amp;gt;&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 ++lib/citations/subject/screen.xml&lt;br /&gt;
 Untitled subject&lt;br /&gt;
&lt;br /&gt;
 ++archives/ipszilon/cfg/citations/document/default.xml&lt;br /&gt;
 (Requires a viewer)&lt;br /&gt;
&lt;br /&gt;
 ++archives/ipszilon/cfg/citations/eprint/default.xml&lt;br /&gt;
 (ed -- eds) thesis&lt;br /&gt;
&lt;br /&gt;
 ++archives/ipszilon/cfg/citations/eprint/result.xml&lt;br /&gt;
 (Item not available online/availability restricted)&lt;br /&gt;
&lt;br /&gt;
 archives/ipszilon/cfg/citations/eprint/thread_commentary.xml&lt;br /&gt;
 (ed -- eds) deposited !!!! (???)&lt;br /&gt;
&lt;br /&gt;
 archives/ipszilon/cfg/citations/eprint/thread_succeeds.xml&lt;br /&gt;
 deposited&lt;br /&gt;
&lt;br /&gt;
  archives/ipszilon/cfg/citations/user/default.xml&lt;br /&gt;
 Unnamed user with... (2x)&lt;br /&gt;
&lt;br /&gt;
 archives/ipszilon/cfg/workflows/eprint/default.xml&lt;br /&gt;
 Publication details (several titles, e.g. Publication  details)&lt;br /&gt;
&lt;br /&gt;
 archives/ipszilon/cfg/workflows/user/default.xml&lt;br /&gt;
 Editorial alerts (title, 2x)&lt;br /&gt;
&lt;br /&gt;
See tech list references [http://www.eprints.org/tech.php/7095.html 7095]  and [http://www.eprints.org/tech.php/7157.html 7157].&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Workflow_Format&amp;diff=4577</id>
		<title>Workflow Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Workflow_Format&amp;diff=4577"/>
		<updated>2007-07-05T08:41:30Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Components */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{formats}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The EPrints 3 workflow configuration files are stored in the repository's [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]] directory, within folders identifying the [[Data Object]]s to which they apply (e.g. eprint or user). Multiple workflows may be defined in each folder, although typically only the default.xml file will be necessary.&lt;br /&gt;
&lt;br /&gt;
== Structure ==&lt;br /&gt;
&lt;br /&gt;
At the centre of a workflow is a 'flow' description. This denotes the path through the workflow process from stage to stage. This may contain EPrints Control tags, allowing for the flow to vary depending on parameters of the data object (or other objects). For example, the flow may be different for users with certain roles. The flow is structured like so:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;flow&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;type&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;files&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;core&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;subjects&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/flow&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The 'ref' attribute of the stage element refers to the individual stages. The stage elements describe the components within each screen of the process and, like flow, may contain EPrints Control tags. The 'name' attribute of the stage element is identical to that of the stage element in the 'flow' section.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;core&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component&amp;gt;&amp;lt;field ref=&amp;quot;title&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component&amp;gt;&amp;lt;field ref=&amp;quot;abstract&amp;quot;/&amp;gt;&amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
== Components ==&lt;br /&gt;
&lt;br /&gt;
An EPrints component is responsible for the rendering of a graphical element in a workflow. This may be a text-box for title entry, a collection of fields in an appropriate grouping, or just a piece of XHTML. Six components are provided by default and, as they are plugins, it is straightforward to drop in new components when necessary. The type attribute of the component element corresponds to the plugin to be used.&lt;br /&gt;
&lt;br /&gt;
If no type is given, type=&amp;quot;Field&amp;quot; is assumed. For each component two further attributes are accepted: surround should be a plugin, by default it can be &amp;quot;None&amp;quot;, &amp;quot;Normal&amp;quot;, and &amp;quot;Light&amp;quot;; and collapse=&amp;quot;yes&amp;quot;. If collapse=&amp;quot;yes&amp;quot; then it tries to render the component collapsed.&lt;br /&gt;
&lt;br /&gt;
== Field-Related Components ==&lt;br /&gt;
&lt;br /&gt;
=== Field Element ===&lt;br /&gt;
&lt;br /&gt;
The majority of field-related components in EPrints 3 make use of the field element in their configuration. This provides a reference to a metafield and any attributes which may be relevant to rendering or operation. Several attributes are available to the element:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;Attribute&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Values&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Description&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt; &lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;ref&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A string&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(required) Refers to the name of the metafield this field represents&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;required&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;yes/no&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) Whether a value is required in this field before the workflow may complete&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;help&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;An XHTML block&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) A block of XHTML to be rendered as help for the field&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;input_lookup_url&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A URL&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) The location of an auto-lookup URL for the field&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;input_lookup_params&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A string&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) An&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Workflow_Format&amp;diff=4576</id>
		<title>Workflow Format</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Workflow_Format&amp;diff=4576"/>
		<updated>2007-07-05T08:16:11Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Components */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{formats}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The EPrints 3 workflow configuration files are stored in the repository's [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]] directory, within folders identifying the [[Data Object]]s to which they apply (e.g. eprint or user). Multiple workflows may be defined in each folder, although typically only the default.xml file will be necessary.&lt;br /&gt;
&lt;br /&gt;
== Structure ==&lt;br /&gt;
&lt;br /&gt;
At the centre of a workflow is a 'flow' description. This denotes the path through the workflow process from stage to stage. This may contain EPrints Control tags, allowing for the flow to vary depending on parameters of the data object (or other objects). For example, the flow may be different for users with certain roles. The flow is structured like so:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;flow&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;type&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;files&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;core&amp;quot;/&amp;gt;&lt;br /&gt;
   &amp;lt;stage ref=&amp;quot;subjects&amp;quot;/&amp;gt;&lt;br /&gt;
 &amp;lt;/flow&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The 'ref' attribute of the stage element refers to the individual stages. The stage elements describe the components within each screen of the process and, like flow, may contain EPrints Control tags. The 'name' attribute of the stage element is identical to that of the stage element in the 'flow' section.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;core&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component&amp;gt;&amp;lt;field ref=&amp;quot;title&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component&amp;gt;&amp;lt;field ref=&amp;quot;abstract&amp;quot;/&amp;gt;&amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
== Components ==&lt;br /&gt;
&lt;br /&gt;
An EPrints component is responsible for the rendering of a graphical element in a workflow. This may be a text-box for title entry, a collection of fields in an appropriate grouping, or just a piece of XHTML. Six components are provided by default and, as they are plugins, it is straightforward to drop in new components when necessary. The type attribute of the component element corresponds to the plugin to be used.&lt;br /&gt;
&lt;br /&gt;
If no type is given, type=&amp;quot;Field&amp;quot; is assumed. Two further attributes are accepted: surround=&amp;quot;whatever...&amp;quot; and collapse=&amp;quot;yes&amp;quot;. These attributes are passed to the appropriate plugin, the second one as if it were collapse=&amp;quot;1&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Field-Related Components ==&lt;br /&gt;
&lt;br /&gt;
=== Field Element ===&lt;br /&gt;
&lt;br /&gt;
The majority of field-related components in EPrints 3 make use of the field element in their configuration. This provides a reference to a metafield and any attributes which may be relevant to rendering or operation. Several attributes are available to the element:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;table border=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;th&amp;gt;Attribute&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Values&amp;lt;/th&amp;gt;&amp;lt;th&amp;gt;Description&amp;lt;/th&amp;gt;&amp;lt;/tr&amp;gt; &lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;ref&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A string&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(required) Refers to the name of the metafield this field represents&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;required&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;yes/no&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) Whether a value is required in this field before the workflow may complete&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;help&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;An XHTML block&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) A block of XHTML to be rendered as help for the field&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;input_lookup_url&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A URL&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) The location of an auto-lookup URL for the field&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;input_lookup_params&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;A string&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;(optional) An&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4575</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4575"/>
		<updated>2007-07-05T07:13:09Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4574</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4574"/>
		<updated>2007-07-05T07:12:15Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 will be used. This means that you can have forward references.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;CAUTION: do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4573</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4573"/>
		<updated>2007-07-05T06:54:43Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Patches */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* [[#Proper utf-8 encoding for outgoing e-mails|proper utf-8 encoding for outgoing e-mails]]&lt;br /&gt;
* [[#Citation phrases with embedded pins|citation phrases with embedded pins]]&lt;br /&gt;
* [[#Phrases using the same link twice|phrases using the same link twice]]&lt;br /&gt;
* [[#Language dependent date and time|expiration time for authentication codes (e.g. at registering) (hardcoded in English)]]&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* [[#Rendering user names depending on session language|user name rendering depends on session language]]&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. The first routine always yields English text; the second one uses the server's locale setting for all languages.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4571</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4571"/>
		<updated>2007-07-04T13:19:10Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Selecting the session's language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]] for all other languages XX except for English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img src=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4570</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4570"/>
		<updated>2007-07-04T13:14:36Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;apache configuration for the whole site&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;apache include files plus indexer log&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives|archives]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID|ArchiveID]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory. Any change you make here has effect on the particular repository only.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subjects &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static/images|images]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static/javascript|javascript]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static/style|style]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how an eprints is read in&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;define the user's data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4569</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4569"/>
		<updated>2007-07-04T12:59:40Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;apache configuration for the whole site&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;apache include files plus indexer log&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives|archives]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID|ArchiveID]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory. Any change you make here has effect on the particular repository only.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how an eprints is read in&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;define the user's data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4568</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4568"/>
		<updated>2007-07-04T12:47:13Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Phrases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]]&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
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 &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4567</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4567"/>
		<updated>2007-07-04T11:41:34Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting document language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]]&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|cfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|cfg/citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|cfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4566</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4566"/>
		<updated>2007-07-04T11:33:32Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting the language of outgoing e-mail messages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]]&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|cfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[lib/defaultcfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[lib/defaultcfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4565</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4565"/>
		<updated>2007-07-04T11:30:29Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory. Any change you make here has effect on the particular repository only.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how an eprints is read in&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;define the user's data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4564</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4564"/>
		<updated>2007-07-04T11:28:25Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory. Any change you make here has effect on the particular repository only.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/eprint|eprint]]&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how an eprints is read in&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
   &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows/user|user]]&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;define the user's data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4562</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4562"/>
		<updated>2007-07-04T11:07:23Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Selecting the session's language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the [[EPrints_Directory_Structure/eprints3/cgi|cgi]] directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]], the English language template for that repository as follows (but see the remarks above):&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English, i.e. insert the following into [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/XX/templates/default.xml]]&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using  [http://files.eprints.org/40/ flag images] to be copied to the directory [[EPrints_Directory_Structure/eprints3/lib/static/style/images|lib/static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[defaultcfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[defaultcfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[lib/defaultcfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[lib/defaultcfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4561</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4561"/>
		<updated>2007-07-04T10:58:03Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Multilingual sites */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting files in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, ''after'' the repository has been created, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]]; if you want this to be the default for all newly created repositories, then edit [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg/lang/en/templates/default.xml]] as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [http://files.eprints.org/40/ flag images] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[defaultcfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[defaultcfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[lib/defaultcfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[lib/defaultcfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4560</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4560"/>
		<updated>2007-07-04T10:19:19Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
In order to costumize EPrints you should make several changes to the configuration files. It is a good time to make yourself familiarize with the  [[EPrints_Directory_Structure/eprints3|EPrints3 Directory Structure]]. Certain files are common for all archives &amp;amp;ndash; &amp;lt;span style=&amp;quot;color:red;&amp;quot;&amp;gt;change these files only if you ''really'' know what your are doing&amp;lt;/span&amp;gt;. Other files are repository specific, any change affects that repository only.&lt;br /&gt;
&lt;br /&gt;
Repository-dependent files are below [[EPrints_Directory_Structure/eprints3/archives|archives]], each repository has it own substructure. When creating a new repository, configuration files are copied from [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]]. Thus making changes in [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg]] or below will effect all ''newly created'' repositories but will have no effect on existing repositories. Probably you want to make certain changes before creating repositories, e.g. adding further languages to [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lib/defaultcfg/lang]] (and also to [[EPrints_Directory_Structure/eprints3/lib/lang|lib/lang]]), changing the default language and available languages in [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|/lib/defaultcfg/cfg.d/languages.pl]], correcting [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|lib/defaultcfg/citations]] and [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/workflows|lib/defaultcfg/workflows]], etc.&lt;br /&gt;
&lt;br /&gt;
In the description below we assume that you've set the repository, and use directories and file names, whenever appropriate, relative to that repository. It should be straightforward to make these changes so that they will have effect for all newly created archives.&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. As the the default page template is repository dependent, ''after'' the repository has been created, you should edit [[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|archives/ArchiveID/lang/en/templates/default.xml]]; if you want this to be the default for all newly created repositories, then edit [[EPrints_Directory_Structure/eprints3/lib/defaultcfg|lib/defaultcfg/lang/en/templates/default.xml]] as follows:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [http://files.eprints.org/40/ flag images] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[defaultcfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[defaultcfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[lib/defaultcfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[lib/defaultcfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4559</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4559"/>
		<updated>2007-07-04T09:16:19Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory. Any change you make here has effect on the particular repository only.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4558</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4558"/>
		<updated>2007-07-04T07:23:47Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command. Initially the &amp;quot;archives&amp;quot; directory is empty, it is populated when executing (as the eprints user) the &amp;quot;bin/epadmin create&amp;quot; command. The new repository is created using the data in the [[EPrints_Directory_Structure/eprints3/lib/defaultcfg]] directory.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory:&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4556</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4556"/>
		<updated>2007-07-03T14:47:11Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
&lt;br /&gt;
A graphical representation of the [[EPrints Directory Structure|EPrints3 directory structure]] after executing the install.pl command.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory:&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4555</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4555"/>
		<updated>2007-07-03T14:33:41Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory:&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject &amp;amp;#91;&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;&amp;amp;#03;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d|cfg.d]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete|autocomplete]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint&amp;quot;&amp;gt;eprint&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets|namedsets]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates|templates]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4554</id>
		<title>EPrints Directory Structure Tree</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure_Tree&amp;diff=4554"/>
		<updated>2007-07-03T14:19:45Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;perl routines&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/bin|bin]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png|-&amp;amp;gt;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;command line and crontab tools&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/cgi|cgi]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;dynamic (cgi) EPrints web pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;defaultcfg&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;empty directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/testdata|testdata]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;10&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;tools and sample test data&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib|lib]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/defaultcfg|defaultcfg]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;the content of&amp;lt;/i&amp;gt; archives/ID/cfg/ &amp;lt;i&amp;gt;is copied from here&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
  &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations|citations]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/lib/citations/saved_search|saved_search]]&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render a stored search&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/subject|subject]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render subjects&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/citations/user|user]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;how to render users&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png|&amp;quot;-&amp;amp;gt;&amp;quot;]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes|themes]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/example|example]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/themes/green|green]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;static&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;style files and pictures&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows|workflows]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/workflows/saved_search|saved_search]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;4&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;workflow for stored search pages&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang|lang]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/phrases|phrases]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;system-wide phrases&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[EPrints_Directory_Structure/eprints3/lib/lang/en/static|static]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;web pages and icons&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;archives&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;ArchiveID&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[[Image:jobbra.png]]&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;&amp;amp;#91;&amp;lt;i&amp;gt;see below&amp;lt;/i&amp;gt;&amp;amp;#93;&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The content of the  &amp;quot;archives/[ArchiveID]/&amp;quot; directory:&lt;br /&gt;
&amp;lt;div style=&amp;quot;margin:2em; background-color:#e9e9e9;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;table cellpadding=&amp;quot;0&amp;quot; cellspacing=&amp;quot;2&amp;quot; style=&amp;quot;margin: 6px;&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents&amp;quot;&amp;gt;documents&amp;lt;/a&amp;gt;&amp;amp;nbsp;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;uploaded files, extracted words, abstract pages, etc.&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html&amp;quot;&amp;gt;html&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;static files for the repository on all languages&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var&amp;quot;&amp;gt;var&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;various repository dependent files&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg&amp;quot;&amp;gt;cfg&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/static&amp;quot;&amp;gt;static&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;7&amp;quot;&amp;gt;subject [&amp;lt;i&amp;gt;used for importing the subject tree&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;images&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;javascript&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;style&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;files to be copied to the html directory&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/cfg.d&amp;quot;&amp;gt;cfg.d&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;general configuration files as perl script fragments&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/autocomplete&amp;quot;&amp;gt;autocomplete&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;data files for the autocompletion feature&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations&amp;quot;&amp;gt;citations&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document&amp;quot;&amp;gt;document&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;document formats&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint&amp;quot;&amp;gt;eprint&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;eprints formats&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user&amp;quot;&amp;gt;user&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;3&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;user formats&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/namedsets&amp;quot;&amp;gt;namedsets&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td colspan=&amp;quot;5&amp;quot;&amp;gt;[&amp;lt;i&amp;gt;files containing the possible values for different sets&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang&amp;quot;&amp;gt;lang&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;XX (langid)&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/phrases&amp;quot;&amp;gt;phrases&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[&amp;lt;i&amp;gt;phrases used locally&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/static&amp;quot;&amp;gt;static&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[&amp;lt;i&amp;gt;templates for static html pages&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;a href=&amp;quot;http://wiki.eprints.org/w/EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/lang/en/templates&amp;quot;&amp;gt;templates&amp;lt;/a&amp;gt;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;&amp;lt;img src=&amp;quot;jobbra.png&amp;quot; alt=&amp;quot;-&amp;gt;&amp;quot;&amp;lt;/td&amp;gt;&lt;br /&gt;
    &amp;lt;td&amp;gt;[&amp;lt;i&amp;gt;default html page template&amp;lt;/i&amp;gt;]&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=File:Jobbra.png&amp;diff=4553</id>
		<title>File:Jobbra.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=File:Jobbra.png&amp;diff=4553"/>
		<updated>2007-07-03T13:55:44Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: right arrow&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;right arrow&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=File:Image-jobbra.png&amp;diff=4552</id>
		<title>File:Image-jobbra.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=File:Image-jobbra.png&amp;diff=4552"/>
		<updated>2007-07-03T13:49:43Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: right arrow&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;right arrow&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure&amp;diff=4551</id>
		<title>EPrints Directory Structure</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=EPrints_Directory_Structure&amp;diff=4551"/>
		<updated>2007-07-03T13:28:53Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
*eprints3/&lt;br /&gt;
** '''AUTHORS''' - Text file telling you who did what in EPrints.&lt;br /&gt;
** '''CHANGELOG''' - Text file documenting every single change made since EPrints 2 Alpha.&lt;br /&gt;
** '''COPYING''' - The GPL License &lt;br /&gt;
** '''NEWS''' - Summary of major changes between versions.&lt;br /&gt;
** '''README''' - Text file telling you how to install and where to find help.&lt;br /&gt;
** '''SIGNATURES''' - Checksums of installed files. Used by upgrade tool to see if files have been modified since installation.&lt;br /&gt;
** '''VERSION''' - The current version of EPrints.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives|archives/]]''' - Contains configuration and data for each repository&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/bin|bin/]]''' - Contains command line tools.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/cfg|cfg/]]''' - Contains site-wide configuration files.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/cgi|cgi/]]''' - Contains CGI files (dynamic web pages)&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/lib|lib/]]''' - Contains the read-only data used by EPrints (do not edit!)&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/perl_lib|perl_lib/]]''' - Contains the perl-libraries used by EPrints&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/testdata|testdata/]]''' - Contains a tool + data to import example data into your repository.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/var|var/]]''' - Used to store files output by EPrints including logs and process ID files.&lt;br /&gt;
&lt;br /&gt;
A graphical tree-like [[EPrints Directory Structure Tree|expansion]] of this  structure.&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Archives/ARCHIVEID/&amp;diff=4550</id>
		<title>Archives/ARCHIVEID/</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Archives/ARCHIVEID/&amp;diff=4550"/>
		<updated>2007-07-03T12:19:39Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
This is the top level directory for a single repository.&lt;br /&gt;
&lt;br /&gt;
It would not be called &amp;quot;ARCHIVEID&amp;quot; it would be called a sensible lowercase string to identify this repository.&lt;br /&gt;
&lt;br /&gt;
*'''[[EPrints_Directory_Structure/eprints3|eprints3]]/[[EPrints_Directory_Structure/eprints3/archives|archives]]/ARCHIVEID'''&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg/]]''' - The repository configuration files.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/documents|documents/]]''' - Uploaded documents. Also contains per-record files such as full-text caches, thumbnails and revision history.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/html|html/]]''' - The website for this repository. Do not edit by hand.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/var|var/]]''' - Files generated by eprints specific to this repository.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/static|static/]]''' - Files which are copied to the website without any processing&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Archives/ARCHIVEID/cfg/citations/&amp;diff=4549</id>
		<title>Archives/ARCHIVEID/cfg/citations/</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Archives/ARCHIVEID/cfg/citations/&amp;diff=4549"/>
		<updated>2007-07-03T11:15:59Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{dirs}}&lt;br /&gt;
This directory contains sub-directories for different types of [[Data Object]]. &lt;br /&gt;
&lt;br /&gt;
*'''[[EPrints_Directory_Structure/eprints3|eprints3]]/[[EPrints_Directory_Structure/eprints3/archives|archives]]/[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID|ARCHIVEID]]/[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg|cfg]]/citations'''&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/document|document/]]''' - [[Document Object]] citation configurations.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/eprint|eprint/]]''' - [[EPrint Object]] citation configurations.&lt;br /&gt;
** '''[[EPrints_Directory_Structure/eprints3/archives/ARCHIVEID/cfg/citations/user|user/]]''' - [[User Object]] citation configurations.&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4548</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4548"/>
		<updated>2007-07-03T08:18:20Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting document language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. You might want to edit [[/lang/en/templates/default.xml]] to include this possibility there:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [http://files.eprints.org/40/ flag images] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[defaultcfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[defaultcfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in [[cfg.d/document_fields_default.pl]] to the language of the session. The available values are listed in [[lib/defaultcfg/namedsets/languages]], you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the [[citations/document/default.xml]] file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see [[lib/defaultcfg/namedsets/document]] )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language in the actual language (defined as the phrase &amp;quot;&amp;lt;tt&amp;gt;languages_typename_XX&amp;lt;/tt&amp;gt;&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied the &amp;quot;Citation phrases with embedded pins&amp;quot; patch in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4547</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4547"/>
		<updated>2007-07-03T08:04:21Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Setting the language of outgoing e-mail messages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. You might want to edit [[/lang/en/templates/default.xml]] to include this possibility there:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [http://files.eprints.org/40/ flag images] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let the users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
[[defaultcfg/cfg.d/user_fields_automatic.pl]] for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the [[defaultcfg/workflows/user/default.xml]] workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrase files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply the &amp;quot;Proper utf-8 encoding for outgoing e-mails&amp;quot; patch from the [[#Patches]] section. Also, by default, the text version of the e-mail does not contain links. This is also corrected by this patch.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in cfg.d/document_fields_default.pl to the language of the session. The available values are listed in lib/defaultcfg/namedsets/languages, you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the citations/document/default.xml file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see lib/defaultcfg/namedsets/document )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied some of the patches in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4546</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4546"/>
		<updated>2007-07-03T07:56:17Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Selecting the session's language */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [http://files.eprints.org/264/ port] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. You might want to edit [[/lang/en/templates/default.xml]] to include this possibility there:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [http://files.eprints.org/40/ flag images] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see the [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
defaultcfg/cfg.d/user_fields_automatic.pl for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the defaultcfg/workflows/user/default.xml workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrases files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply some patches from the [[#Patches]] section. Also, the text version of the e-mails does not containt the links. This can also be corrected by one of the patches.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in cfg.d/document_fields_default.pl to the language of the session. The available values are listed in lib/defaultcfg/namedsets/languages, you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the citations/document/default.xml file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see lib/defaultcfg/namedsets/document )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied some of the patches in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Manual&amp;diff=4543</id>
		<title>Manual</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Manual&amp;diff=4543"/>
		<updated>2007-07-03T07:22:52Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Misc */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;See the [[Main Page]] for other areas of this wiki.&lt;br /&gt;
__NOTOC__&lt;br /&gt;
= Introduction =&lt;br /&gt;
&lt;br /&gt;
* [[Introduction]]&lt;br /&gt;
* How to Get Help/Support&lt;br /&gt;
* [[History]] &lt;br /&gt;
&lt;br /&gt;
= Installing EPrints &amp;amp; Getting Started =&lt;br /&gt;
&lt;br /&gt;
* [[Required software]]&lt;br /&gt;
* [[Installation|Installing EPrints]]&lt;br /&gt;
** [[Recommended Platforms]]&lt;br /&gt;
** [[Installing Eprints 3 on Fedora Core 6]]&lt;br /&gt;
** [[Installing EPrints 3 on RedHat Enterprise 4]]&lt;br /&gt;
** [[Installing EPrints 3 on OS X]]&lt;br /&gt;
** [[Installing EPrints 3 on Ubuntu 6.10]]&lt;br /&gt;
** ''[[:Category:Installation|other platforms]]''&lt;br /&gt;
* [[Upgrading EPrints 3 versions]]&lt;br /&gt;
* [[Migration|Migrating from EPrints 2.3]]&lt;br /&gt;
* [[Getting Started with EPrints 3|Getting Started]]&lt;br /&gt;
* [[Backups]]&lt;br /&gt;
* [[Troubleshooting]]&lt;br /&gt;
* Advanced Installation&lt;br /&gt;
** [[Https3]]&lt;br /&gt;
* [[:Category:Installation|Installing]] EPrints on various platforms.&lt;br /&gt;
&lt;br /&gt;
= How-to Guides =&lt;br /&gt;
&lt;br /&gt;
''[http://en.wikipedia.org/wiki/Howto What is a how-to?]&lt;br /&gt;
&lt;br /&gt;
* Orientation &amp;lt;span style=&amp;quot;color: #f94; font-size: 130%&amp;quot;&amp;gt;(Start here)&amp;lt;/span&amp;gt;&lt;br /&gt;
** [[Configuration orientation|New to EPrints 3?]]  - ''before diving into the how-tos, take some time to read through this brief orientation guide and familiarise yourself with the EPrints configuration landscape...''&lt;br /&gt;
** [[EPrints_3_Configuration_orientation_for_EPrints_2_administrators|Migrated from EPrints 2?]] - ''this orientation guide is intended to help you re-orient yourselves in your new EPrints 3 set up...'' &lt;br /&gt;
* [[Branding with confidence]] - ''one of the most common EPrints customisations is to add your own institution's branding and &amp;quot;look and feel&amp;quot; to the interface...''&lt;br /&gt;
** [[Branding, the next level]] - ''how to completely change the interface to your own design''&lt;br /&gt;
* [[Adding new views]]&lt;br /&gt;
* Workflow&lt;br /&gt;
* Deposit Types&lt;br /&gt;
** [[Removing types]]&lt;br /&gt;
* Metadata&lt;br /&gt;
* Subjects (fold in with Organisation Hierarchy under &amp;quot;controled vocabularies&amp;quot;)&lt;br /&gt;
* [[EPrints_3_Organisation_Hierarchy|Organisation Hierarchy]] - ''how to put your own organisation's Hierarchy into EPrints 3''&lt;br /&gt;
* Searches&lt;br /&gt;
* [[Autocompletion and Authority Files (Romeo Autocomplete)]] - ''add autocomplete functionality to the Publication Title input field based on an authority file downloaded from EPrints Romeo...''&lt;br /&gt;
* [[Create Export Plugins]] - ''create a Perl Module that will export your data...''&lt;br /&gt;
* [[Login-Only Repository]] - ''require a username and password to access all pages (including search, browse, and the front page)...''&lt;br /&gt;
* [[Change Deposit Status in Bulk]] - ''move a large number of deposits from inbox to archive&lt;br /&gt;
* [[Customisation|more]]&lt;br /&gt;
&lt;br /&gt;
= Misc =&lt;br /&gt;
&lt;br /&gt;
* [[Preservation Support]] in GNU EPrints 3&lt;br /&gt;
* [[i18n]]&lt;br /&gt;
* [[How to contribute]]&lt;br /&gt;
** [[Extension Packages]]&lt;br /&gt;
&lt;br /&gt;
= Technical Reference =&lt;br /&gt;
&lt;br /&gt;
* [[EPrints Directory Structure]] - will be linked somewhere better, later.&lt;br /&gt;
&lt;br /&gt;
* [[Metadata]] - configuring metadata fields.&lt;br /&gt;
* [[Archives/ARCHIVEID/cfg/|Repository Configuration]]&lt;br /&gt;
* [[XML Configuration]] Files&lt;br /&gt;
** [[EPScript]] - documentation for the EP3 Scripting language (for use in citations and workflow files).&lt;br /&gt;
** [[EPrints Control Format]] - the structure used to embed EPScript in an XML configuration file.&lt;br /&gt;
** [[Citation Format]]&lt;br /&gt;
** [[Workflow Format]] - the structure of the EP3 workflow files&lt;br /&gt;
** [[Phrase Format]]&lt;br /&gt;
** [[Template Format]]&lt;br /&gt;
** [[XPAGE Format]]&lt;br /&gt;
* [[XML Export Format]]&lt;br /&gt;
* EPrints data structure &lt;br /&gt;
** of the software&lt;br /&gt;
** of the database (relating the dataobjects to each other using eprints fields)&lt;br /&gt;
* [[Data Object]]s and data sets&lt;br /&gt;
** The [[EPrint Object]]&lt;br /&gt;
** The [[User Object]]&lt;br /&gt;
** The [[Document Object]]&lt;br /&gt;
** The [[Subject Object]]&lt;br /&gt;
** The [[Saved Search Object]]&lt;br /&gt;
** The [[History Object]]&lt;br /&gt;
** The [[Access Object]]&lt;br /&gt;
** The [[Request Object]]&lt;br /&gt;
* Plugins&lt;br /&gt;
** Import&lt;br /&gt;
** [[Export Plugins]]&lt;br /&gt;
** Components&lt;br /&gt;
** Screen&lt;br /&gt;
** Convert&lt;br /&gt;
* [[Autocompletion]]&lt;br /&gt;
** [[Understanding IDs in Workflow Forms]]&lt;br /&gt;
* [[API]]&lt;br /&gt;
* [[Dynamic Template System]]&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4542</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4542"/>
		<updated>2007-07-02T15:04:01Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Citation phrases with embedded pins */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [[http://files.eprints.org/264/ port]] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. You might want to edit [[/lang/en/templates/default.xml]] to include this possibility there:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [[http://files.eprints.org/40/ flag images]] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
defaultcfg/cfg.d/user_fields_automatic.pl for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the defaultcfg/workflows/user/default.xml workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrases files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply some patches from the [[#Patches]] section. Also, the text version of the e-mails does not containt the links. This can also be corrected by one of the patches.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in cfg.d/document_fields_default.pl to the language of the session. The available values are listed in lib/defaultcfg/namedsets/languages, you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the citations/document/default.xml file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see lib/defaultcfg/namedsets/document )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied some of the patches in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [http://www.eprints.org/tech.php/7236.html 7236].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
	<entry>
		<id>https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4541</id>
		<title>Translation</title>
		<link rel="alternate" type="text/html" href="https://wiki.eprints.org/w/index.php?title=Translation&amp;diff=4541"/>
		<updated>2007-07-02T07:19:56Z</updated>

		<summary type="html">&lt;p&gt;Csirmaz: /* Language dependent date and time */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Making translation to Eprints3 is similar to that of earlier versions. Here only some of the differences are pointed out. Also, there is a difference between just translating, or making a multilingual site. If you are making a translation, then with little effort you can also make your site speak English too, a courtesy for casual visitors of your repository.&lt;br /&gt;
&lt;br /&gt;
== Multilingual sites ==&lt;br /&gt;
&lt;br /&gt;
=== Selecting the session's language ===&lt;br /&gt;
&lt;br /&gt;
In a multilingual site you probably let the visitors to choose the language of the session. It is determined by the default setting of the browser preferences, but sometimes users want to change this. Manual setting of the session's language can be done by the [[http://files.eprints.org/264/ port]] of the ''set_language'' script from earlier Eprints versions, and should go into the cgi directory. A handy place for the set_language URL is in the menu at the top of the page. You might want to edit [[/lang/en/templates/default.xml]] to include this possibility there:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;ul class=&amp;quot;ep_tm_menu&amp;quot;&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{frontpage}}&amp;quot;&amp;amp;gt;Home&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a ref=&amp;quot;{$config{perl_url}}/set_lang&amp;quot;&amp;amp;gt;Language&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
    &amp;amp;lt;li&amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{base_url}}/information.html&amp;quot;&amp;amp;gt;About&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
   ... &lt;br /&gt;
  &amp;amp;lt;/ul&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
The template page on other languages should not contain this ''Language'' item as not neccessarily will people recognise it. Rather use a button which reverts the language to English:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;li&amp;amp;gt;&amp;amp;lt;a href=&amp;quot;{$config{perl_url}/set_lang?langid=en&amp;quot;&amp;amp;gt;In English&amp;amp;lt;/a&amp;amp;gt;&amp;amp;lt;/li&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you want a little more fancy layout, you might consider using the [[http://files.eprints.org/40/ flag images]] to be copied to the directory [[static/style/images/flags/]]. If you define a phrase (see [[#Phrases]] section) of the form &amp;quot;cgi/set_lang:lang_XX&amp;quot; then the set_lang script will use that phrase to render a link to that language. A typical format could be&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;cgi/set_lang:lang_hu&amp;quot;&amp;gt;&amp;lt;epc:pin name=&amp;quot;link&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;amp;lt;img sec=&amp;quot;/style/images/flags/flag_hu.png&amp;quot; alt=&amp;quot;[hu]&amp;quot; /&amp;amp;gt; &lt;br /&gt;
       Hungarian&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
  &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Setting the language of outgoing e-mail messages ===&lt;br /&gt;
&lt;br /&gt;
By default, all e-mail messages are sent out on the default language of the depository. You might let users choose their preferred language so that they'll receive messages on that language. The ''lang'' (system) field is defined for all users; the value can be set automatically in &lt;br /&gt;
defaultcfg/cfg.d/user_fields_automatic.pl for example by&lt;br /&gt;
&lt;br /&gt;
 $c-&amp;gt;{set_user_automatic_fields} = sub&lt;br /&gt;
 { my ( $user ) = @_;&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;frequency&amp;quot; ) )&lt;br /&gt;
   {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;frequency&amp;quot;,&amp;quot;never&amp;quot;);&lt;br /&gt;
    }&lt;br /&gt;
    ## NEW: set default language to the session language&lt;br /&gt;
    if( !$user -&amp;gt; is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
    {&lt;br /&gt;
         $user-&amp;gt;set_value(&amp;quot;lang&amp;quot;,$user-&amp;gt;{session}-&amp;gt;{lang}-&amp;gt;{id});&lt;br /&gt;
    }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
and also let the user edit their own preference by inserting the ''lang'' field in the defaultcfg/workflows/user/default.xml workflow, say in the personal section:&lt;br /&gt;
&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Field::Multi&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;title&amp;gt;&amp;lt;epc:phrase ref=&amp;quot;user_section_personal&amp;quot; /&amp;gt;&amp;lt;/title&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;name&amp;quot; required=&amp;quot;yes&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;lang&amp;quot;/&amp;gt; &amp;amp;lt;-- NEW!!! edit preferred language --&amp;amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;dept&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;org&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;address&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;country&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;url&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;/component&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Finally, you might want the default language appear on the user's profile pages. This needs editing the [[cfg/cfg.d/user_render.pl]] file by inserting the following into the place of your choice (I coose just next to &amp;quot;country&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
  if( $user-&amp;gt;is_set( &amp;quot;lang&amp;quot; ) )&lt;br /&gt;
  {&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;&amp;gt;make_element( &amp;quot;br&amp;quot; ) );&lt;br /&gt;
       $p-&amp;gt;appendChild($session-&amp;gt;html_phrase(&amp;quot;user_preferred_language&amp;quot;,&lt;br /&gt;
                 lang =&amp;gt; $user-&amp;gt;render_value( &amp;quot;lang&amp;quot; ) ) );&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
here the new phrase &amp;quot;user_preferred_language&amp;quot; should be defined in one of the phrases files (see the [[#Phrases]] section); in it the pin &amp;quot;lang&amp;quot; contains the language itself:&lt;br /&gt;
&lt;br /&gt;
  &amp;amp;lt;epp:phrase id=&amp;quot;user_preferred_language&amp;quot;&amp;amp;gt;Preferred language: &lt;br /&gt;
       &amp;amp;lt; epc:pin name=&amp;quot;lang&amp;quot;/&amp;amp;gt;&lt;br /&gt;
  &amp;amp;lt;/epp:phrase&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color:red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; While e-mail messages are sent out utf-8 encoded, they are not properly formatted. For non-English e-mails you must apply some patches from the [[#Patches]] section. Also, the text version of the e-mails does not containt the links. This can also be corrected by one of the patches.&lt;br /&gt;
&lt;br /&gt;
=== Setting document language ===&lt;br /&gt;
&lt;br /&gt;
Each document file has its own language. The same document might be submitted in different languages. In the default eprints workflow the reference to the language field is commented out; you only has to enable it. It is in file [[defaultcfg/workflows/eprint/default.xml]], stage &amp;quot;files&amp;quot;:&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;stage name=&amp;quot;files&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;XHTML&amp;quot;&amp;gt;...&amp;lt;/component&amp;gt;&lt;br /&gt;
   &amp;lt;component type=&amp;quot;Upload&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;format&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;formatdesc&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;security&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;license&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;date_embargo&amp;quot; /&amp;gt;&lt;br /&gt;
      &amp;lt;field ref=&amp;quot;language&amp;quot; /&amp;gt; &amp;amp;lt;!-- UNCOMMENT! --&amp;amp;gt;&lt;br /&gt;
  &amp;lt;/component&amp;gt;&lt;br /&gt;
 &amp;lt;/stage&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The default value is set in cfg.d/document_fields_default.pl to the language of the session. The available values are listed in lib/defaultcfg/namedsets/languages, you might consider revising this set.&lt;br /&gt;
The &amp;quot;undefined&amp;quot; language is a question mark (?).&lt;br /&gt;
&lt;br /&gt;
You might also want to print the language as well. To this end, edit the citations/document/default.xml file. Show the language only when it is set, and the document's mime type is ''text/plain'', ''application/pdf'', ''application/postscript'', ''application/msword'', or ''other''. (For a full list of available mime type see lib/defaultcfg/namedsets/document )&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;cite:linkhere&amp;gt;...&amp;lt;/cite:linkhere&amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;security != 'public'&amp;quot;&amp;gt; ... &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
 &amp;amp;lt;!-- NEW!!! --&amp;amp;gt;&lt;br /&gt;
 &amp;lt;epc:if test=&amp;quot;is_set(language) and format.one_of( 'text/plain' ,&lt;br /&gt;
     'application/pdf', 'application/postscript', 'application/msword', 'other') &amp;gt;&lt;br /&gt;
    &amp;lt;epc:phrase ref=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
         &amp;lt;epc:param name=&amp;quot;lang&amp;quot;&amp;gt;&lt;br /&gt;
              &amp;lt;epc:print expr=&amp;quot;language&amp;quot;/&amp;gt;&lt;br /&gt;
         &amp;lt;/epc:param&amp;gt;&lt;br /&gt;
    &amp;lt;/epc:phrase&amp;gt;&lt;br /&gt;
  &amp;lt;/epc:if&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and, of course, one has to define the &amp;quot;citation:doc_language&amp;quot; phrase (see below) in all languages. In the phrase definition we have the pin &amp;quot;lang&amp;quot; which contains the document language:&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;epp:phrase id=&amp;quot;citation:doc_language&amp;quot;&amp;gt;&lt;br /&gt;
    (The document's language is &amp;lt;epc:pin name=&amp;quot;lang&amp;quot;/&amp;gt;.)&lt;br /&gt;
 &amp;lt;/epp:phrase&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;color: red; font-weight:bold&amp;quot;&amp;gt;WARNING!&amp;lt;/span&amp;gt; The example above works only after you've applied some of the patches in the [[#Patches]] section.&lt;br /&gt;
&lt;br /&gt;
== Phrases ==&lt;br /&gt;
&lt;br /&gt;
Phrase defintions 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.&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
System-wide (i.e. repository independent) phrases are contained in the files in [[lib/lang/XX/phrases/]] where '''XX''' is the language code. Repository dependent phrase files are in [[archives/ARCHIVEID/cfg/lang/XX/phrases/]]. In both directories all files with extension &amp;quot;.xml&amp;quot; are scanned and read in in alphabetical order.  You can split the data into several files instead having a single a huge phrase file.&lt;br /&gt;
&lt;br /&gt;
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:&lt;br /&gt;
&lt;br /&gt;
 &amp;amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;iso-8859-1&amp;quot; standalone=&amp;quot;no&amp;quot; ?&amp;amp;gt;&lt;br /&gt;
&lt;br /&gt;
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.&lt;br /&gt;
&lt;br /&gt;
You can define as many new phrases as you want, and refer them in other phrases. When using a phrase, the most last existing definition is used. This means that you can have forward references with no problem.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;font-size:small;&amp;quot;&amp;gt;Do not attempt to create recursive references, as only your web server will crash after consuming all available memory.&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Other configuration files ==&lt;br /&gt;
&lt;br /&gt;
Several language-independent configuration files contain hardwired English texts. All of them should be replaced by references to phrases, which, in turn, generate the phrases in all languages. The &amp;quot;offending&amp;quot; files are in the ''citations'' and the ''workflows'' directories.&lt;br /&gt;
&lt;br /&gt;
== Subject list ==&lt;br /&gt;
&lt;br /&gt;
== Patches ==&lt;br /&gt;
&lt;br /&gt;
Apart from translating the language dependent phrase files, some other modification should be done for proper functioning. Theses patches are for Eprints version 3.0.1, please check your current version&lt;br /&gt;
&lt;br /&gt;
* proper utf-8 encoding for outgoing e-mails&lt;br /&gt;
* citation phrases with embedded pins&lt;br /&gt;
* phrases where the same link is used twice&lt;br /&gt;
* expiration time for authentication codes (e.g. at registering) (hardcoded in English)&lt;br /&gt;
* generation time for browse pages (harcoded in English)&lt;br /&gt;
* user name rendering depends on session language&lt;br /&gt;
&lt;br /&gt;
=== Proper utf-8 encoding for outgoing e-mails ===&lt;br /&gt;
&lt;br /&gt;
For outgoing e-mails the charset should be &amp;quot;utf-8&amp;quot;. The mail headers (From, To, Subject, Reply-To, etc lines) might contain a restricted set of English characters only, other characters should be encoded. This [[EPrints.pm.diff]] [http://files.eprints.org/273 patch file] corrects these, PLUS it enables the URL text from links into the text version, PLUS converts wide characters to bytes (the Net::SMTP perl routine complains).&lt;br /&gt;
&lt;br /&gt;
See the tech list references [http://www.eprints.org/tech.php/thread-5762.html 5762],&lt;br /&gt;
[http://www.eprints.org/tech.php/5783.html 5783] and&lt;br /&gt;
[http://www.eprints.org/tech.php/7114.html 7114].&lt;br /&gt;
&lt;br /&gt;
=== Citation phrases with embedded pins ===&lt;br /&gt;
&lt;br /&gt;
You need to apply the second half of the [[XML/EPC.pm.diff]] patch if want to use citations with embedded pins. See tech list [[http://www.eprints.org/tech.php/7236.html 7236]].&lt;br /&gt;
&lt;br /&gt;
=== Phrases using the same link twice ===&lt;br /&gt;
&lt;br /&gt;
If in a phrase you are using the same link pin twice, the second time it does not render correctly. E.g. if you want a picture AND a text refer to the same link, such as&lt;br /&gt;
 &amp;lt;ep:phrase id=&amp;quot;two_links&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;&amp;lt;img src=&amp;quot;img.png&amp;quot; alt=&amp;quot;[img]&amp;gt;&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
   &amp;lt;epc:pin ref=&amp;quot;link&amp;quot;&amp;gt;Click here&amp;lt;/epc:pin&amp;gt;&lt;br /&gt;
 &amp;lt;ep:phrase&amp;gt;&lt;br /&gt;
For both links to work correctly please apply the first half of the [[XML/EPC.pm.diff]] patch. See tech list [[http://www.eprints.org/tech.php/6960.html 6960]].&lt;br /&gt;
&lt;br /&gt;
=== Language dependent date and time ===&lt;br /&gt;
&lt;br /&gt;
The wording of grace period (expiration time of the random pin number when someone registers or changes the email address) is generated in the Eprints/Time.pm script by the ''human_delay()'' routine. Also, the creation time at the bottom of browse pages are created here by ''human_time()'. Both routines yield English text.&lt;br /&gt;
&lt;br /&gt;
[http://files.eprints.org/274 This patch] replaces ''human_delay()'' with reference to phrases for hour, day, week and their plural forms. See also tech list [http://www.eprints.org/tech.php/7243.html 7243]&lt;br /&gt;
&lt;br /&gt;
=== Rendering user names depending on session language ===&lt;br /&gt;
&lt;br /&gt;
All fields can have their separate rendering routine. This routine should be given as the value of the ''render_single_value'' attribute. In our case modify the top of cfg.d/user_fields.pl file which contains the definition of the user fields as follows:&lt;br /&gt;
&lt;br /&gt;
  $c-&amp;gt;{fields}-&amp;gt;{user} = [&lt;br /&gt;
      {&lt;br /&gt;
          'name' =&amp;gt; 'name',&lt;br /&gt;
          'type'   =&amp;gt; 'name',&lt;br /&gt;
          'render_order' =&amp;gt; 'gf',&lt;br /&gt;
          'render_single_value' =&amp;gt; \&amp;amp;my_namefield_rendering,&lt;br /&gt;
      },&lt;br /&gt;
      ...&lt;br /&gt;
&lt;br /&gt;
and insert the definition of ''my_namefield_rendering'' e.g. at the end of the same file:&lt;br /&gt;
&lt;br /&gt;
 sub my_namefield_rendering&lt;br /&gt;
 {&lt;br /&gt;
    my ($session,$field,$value,$object)=@_;&lt;br /&gt;
    my $langid = $session-&amp;gt;{lang}-&amp;gt;{id}; &lt;br /&gt;
    my $format = {&lt;br /&gt;
 # format: f, g - first, given; h - honourific, l - lineage&lt;br /&gt;
      'en' =&amp;gt; 'hfl,g',&lt;br /&gt;
      'hu' =&amp;gt; 'hlfg',&lt;br /&gt;
 # Further lines should be added for other used languages&lt;br /&gt;
    } -&amp;gt; {$langid}&lt;br /&gt;
    my $all=&amp;quot;&amp;quot;;&lt;br /&gt;
    foreach my $fmtchar ( split //, $format ) {&lt;br /&gt;
        my $insert=&amp;quot;&amp;quot;;&lt;br /&gt;
        if( $fmtchar eq &amp;quot;l&amp;quot; ) {$insert = $value-&amp;gt;{lineage}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;f&amp;quot; ) { $insert = $value-&amp;gt;{family}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;g&amp;quot; ) { $insert = $value-&amp;gt;{given}; }&lt;br /&gt;
        elsif( $fmtchar eq &amp;quot;h&amp;quot; ) { $insert = $value-&amp;gt;{honourific}; }&lt;br /&gt;
        elsif( $all ){ $all .= $fmtchar; }&lt;br /&gt;
        next if( ! $insert );&lt;br /&gt;
        $all .= $insert;&lt;br /&gt;
    }&lt;br /&gt;
    my $span=$session-&amp;gt;make_element(&amp;quot;span&amp;quot;,class=&amp;gt;&amp;quot;person_name&amp;quot;);&lt;br /&gt;
    $span-&amp;gt;appendChild($session-&amp;gt;make_text($all));&lt;br /&gt;
    $return $span;&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Indexing ==&lt;/div&gt;</summary>
		<author><name>Csirmaz</name></author>
		
	</entry>
</feed>