<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New","serif";
        color:black;}
tt
        {mso-style-priority:99;
        font-family:"Courier New","serif";}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        color:black;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle21
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle22
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";
        color:black;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor="white" lang="EN-GB" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Hi,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">I think that everything that is needed is in the Bazaar example I linked to – and possibly some of your steps have stopped things working!?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">- new versions of EPrints already have a ‘set_lang’ script in cgi (I wonder if you’ve copied an older version over the top of this current version (see:
<a href="https://github.com/eprints/eprints/blob/3.3/cgi/set_lang">https://github.com/eprints/eprints/blob/3.3/cgi/set_lang</a> for the current one).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">I’ve just enabled the Spanish language pack on
<a href="http://demoprints.eprints.org/">http://demoprints.eprints.org/</a> (you can create an admin account on there, and install things :o).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">The link to change languages appears without doing anything to the templates.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">So maybe start by reverting your change to set_lang &nbsp;&nbsp;and see how that helps.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Cheers,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">John<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext"> eprints-tech-bounces@ecs.soton.ac.uk
 [mailto:eprints-tech-bounces@ecs.soton.ac.uk] <b>On Behalf Of </b>George Mamalakis<br>
<b>Sent:</b> 15 May 2015 14:26<br>
<b>To:</b> eprints-tech@ecs.soton.ac.uk<br>
<b>Subject:</b> [EP-tech] Re: Antwort: Multilingual site<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<div>
<p class="MsoNormal">John Hi,<br>
<br>
Yes I've included el in the specific variable. To make things easier for you, I'll repost what I've posted in stackoverflow:<br>
<br>
&quot;I have downloaded and unzipped the greek translation (for an earlier version, 3.0, from the official site) on the folders that seemed appropriate, I have placed the set_lang script in the cgi folder and changed the template to use it, I have changed languages.pl
 to include 'el' as well, I have re-generated statics and now the html folder contains my Greek index.html, I have restarted apache&quot;<br>
<br>
Thank you for prompting me on the Spanish Language Pack, I'll see what changes I'll have to still make in order to complete the Greek translation. But before that, I hope I'll manage to see the translated site :).<br>
<br>
As far as the plugin is concerned: apart from copying the set_lang script on the cgi folder and adding appropriate content in the template to use it (by calling cgi/set_lang?langid=el) is there something else that needs to be done?<br>
<br>
Otherwise: as far as the core system is concerned. How does it know that it is &quot;ready&quot; to start servicing a multilingual site? Is it enough to add an additional language in $c-&gt;{languages} (of ~/archives/ARCHIVEID/cfg/cfg.d/languages.pl) and copy the translation
 file in the cfg/lang/XX folder? Or does it need something additional that I am missing?<br>
<br>
Thanks again for your time and help!<br>
<br>
On 15/05/2015 03:51 μμ, John Salter wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Hi George,</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Have you added anything to ~/archives/ARCHIVEID/cfg/cfg.d/languages.pl?</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">By default it’s something like:</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">$c-&gt;{defaultlanguage} = 'en';</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">$c-&gt;{languages} = [ 'en' ];</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">You should add the new language in&nbsp; the second option e.g.:</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">$c-&gt;{languages} = [ 'en', 'el' ];</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">The newer way of doing things is shown in this EPrints Bazaar package (unfortunately for Spanish, not Greek):
<a href="http://bazaar.eprints.org/227/">http://bazaar.eprints.org/227/</a> . In the file x_lang_es.pl, it achieves the same thing with:
</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">push @{$c-&gt;{languages}},'es';</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">I’d take this Bazaar package as a base for how to do things – e.g. which files would need to be translated.</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Many of the phrases would exist in the 3.0 translation you’ve installed – but some won’t.</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Let me know if that gets you any further down the path – and we can go from there!</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">Cheers,</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">John</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">PS I don’t have any real experience of working with multi-lingual repositories – but have tried to learn bits!</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D">&nbsp;</span><o:p></o:p></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;color:windowtext">
<a href="mailto:eprints-tech-bounces@ecs.soton.ac.uk">eprints-tech-bounces@ecs.soton.ac.uk</a> [<a href="mailto:eprints-tech-bounces@ecs.soton.ac.uk">mailto:eprints-tech-bounces@ecs.soton.ac.uk</a>]
<b>On Behalf Of </b>George Mamalakis<br>
<b>Sent:</b> 15 May 2015 13:13<br>
<b>To:</b> <a href="mailto:eprints-tech@ecs.soton.ac.uk">eprints-tech@ecs.soton.ac.uk</a><br>
<b>Subject:</b> [EP-tech] Re: Antwort: Multilingual site</span><o:p></o:p></p>
</div>
</div>
<p class="MsoNormal">&nbsp;<o:p></o:p></p>
<div>
<p class="MsoNormal">Martin, hi and thanks for your answer!<br>
<br>
I have generated static, the html folder of my deposit has been populated with the correct html files (I've looked into their content), and when I select the Greek language through an href (on an image), as I said, it displays the &quot;language has changed&quot; page
 in Greek, but when I click on any link (menu, whatever) the content served is in English.<br>
<br>
I have used Chrome, Firefox and Opera and it won't work in any of them.<br>
<br>
I have to re-inform you that I installed the Greek translation (which is for a previous version of eprints, 3.0) without using any guide, which means that I just copied the folders contained in the zip file where it seemed appropriate (./lib/defaultcfg and
 ./lib/lang in the eprints folder, and cfg/lang/el in the specific archive). As I read in eprints' documentation regarding previous versions (&lt;3), a few stuff needed to be done in order to install translations, that didn't seem &quot;compatible&quot; with my version.
 Maybe I am missing something here...<br>
<br>
If not, then I am not sure what part of eprints' core functionality fails and doesn't load the language correctly or if the problem is related to the set_lang script.<br>
<br>
Thanks again for your answer!<br>
<br>
PS. I wasn't sure about the activity of this list, so a few hours ago (before receiving your answer) I started an analogous question in stackoverflow:
<a href="http://stackoverflow.com/questions/30254057/eprints-multilingual-site">http://stackoverflow.com/questions/30254057/eprints-multilingual-site</a><br>
<br>
On 15/05/2015 11:03 πμ, <a href="mailto:martin.braendle@id.uzh.ch">martin.braendle@id.uzh.ch</a> wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Hi,</span><br>
<br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">two questions come to my mind:</span><br>
<br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">- did you run bin/generate_static &nbsp;your_repo --prune &nbsp; &nbsp;?</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">- which browser did you use to test? Safari sends a slightly different Accept-Language token in the HTTP header, which is not properly recognized by Repository.pm.</span><br>
<br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">A possible patch is:</span><br>
<br>
<tt><span style="font-size:10.0pt">Modified: trunk/src/core/perl_lib/EPrints/Repository.pm</span></tt><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;,&quot;serif&quot;"><br>
<tt>===================================================================</tt><br>
<tt>--- trunk/src/core/perl_lib/EPrints/Repository.pm 2014-08-12 12:23:41 UTC (rev 857)</tt><br>
<tt>&#43;&#43;&#43; trunk/src/core/perl_lib/EPrints/Repository.pm 2014-09-10 13:00:28 UTC (rev 858)</tt><br>
<tt>@@ -2264,6 &#43;2264,8 @@</tt><br>
<tt>foreach my $browser_lang ( split( /, */, $accept_language ) )</tt><br>
<tt>{</tt><br>
<tt>$browser_lang =~ s/;.*$//;</tt><br>
<tt>&#43; # UZH CHANGE ZORA-274 fix for Safari browser 2014/08/15/mb</tt><br>
<tt>&#43; $browser_lang =~ s/-.*$//;</tt><br>
<tt>push @prefs, $browser_lang;</tt><br>
<tt>}</tt><br>
<tt>}</tt></span><br>
<br>
<br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Best regards,</span><br>
<br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Martin</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">&nbsp;</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">--</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Dr. Martin Brändle</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Zentrale Informatik</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Universität Zürich</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">Winterthurerstr. 190</span><br>
<span style="font-size:10.0pt;font-family:&quot;Arial&quot;,&quot;sans-serif&quot;">CH-8057 Zürich</span><o:p></o:p></p>
</blockquote>
<p class="MsoNormal"><br>
<br>
<br>
<br>
<o:p></o:p></p>
<pre>-- <o:p></o:p></pre>
<pre>George Mamalakis<o:p></o:p></pre>
<pre>&nbsp;<o:p></o:p></pre>
<pre>IT and Security Officer, <o:p></o:p></pre>
<pre>Electrical and Computer Engineer (Aristotle Univ. of Thessaloniki),<o:p></o:p></pre>
<pre>PhD (Aristotle Univ. of Thessaloniki),<o:p></o:p></pre>
<pre>MSc (Imperial College of London)<o:p></o:p></pre>
<pre>&nbsp;<o:p></o:p></pre>
<pre>School of Electrical and Computer Engineering<o:p></o:p></pre>
<pre>Aristotle University of Thessaloniki<o:p></o:p></pre>
<pre>&nbsp;<o:p></o:p></pre>
<pre>phone number : &#43;30 (2310) 994379<o:p></o:p></pre>
<pre>&nbsp;<o:p></o:p></pre>
<pre>&nbsp;<o:p></o:p></pre>
<p class="MsoNormal"><br>
<br>
<br>
<o:p></o:p></p>
<pre>*** Options: <a href="http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech">http://mailman.ecs.soton.ac.uk/mailman/listinfo/eprints-tech</a><o:p></o:p></pre>
<pre>*** Archive: <a href="http://www.eprints.org/tech.php/">http://www.eprints.org/tech.php/</a><o:p></o:p></pre>
<pre>*** EPrints community wiki: <a href="http://wiki.eprints.org/">http://wiki.eprints.org/</a><o:p></o:p></pre>
<pre>*** EPrints developers Forum: <a href="http://forum.eprints.org/">http://forum.eprints.org/</a><o:p></o:p></pre>
</blockquote>
<p class="MsoNormal"><br>
<br>
<br>
<o:p></o:p></p>
<pre>-- <o:p></o:p></pre>
<pre>George Mamalakis<o:p></o:p></pre>
<pre><o:p>&nbsp;</o:p></pre>
<pre>IT and Security Officer, <o:p></o:p></pre>
<pre>Electrical and Computer Engineer (Aristotle Univ. of Thessaloniki),<o:p></o:p></pre>
<pre>PhD (Aristotle Univ. of Thessaloniki),<o:p></o:p></pre>
<pre>MSc (Imperial College of London)<o:p></o:p></pre>
<pre><o:p>&nbsp;</o:p></pre>
<pre>School of Electrical and Computer Engineering<o:p></o:p></pre>
<pre>Aristotle University of Thessaloniki<o:p></o:p></pre>
<pre><o:p>&nbsp;</o:p></pre>
<pre>phone number : &#43;30 (2310) 994379<o:p></o:p></pre>
<pre><o:p>&nbsp;</o:p></pre>
<pre><o:p>&nbsp;</o:p></pre>
</div>
</body>
</html>