Hi Alec
For many rtl languages such as Farsi, I think it is not only necessary to change the page direction, but also a handfull of extra settings may be necessary to display the page in the correct way. These extra settings may include some extra spaces ( ) between navigation menu items, changing the font faces and sizes, altering margins and paddings, changing the float attribute of sidebar to other side, exchanging majority of lefts with rights in css files. So if these configurations are included in the 'journalStyleSheet.css' file (or other stylesheets), this may cause inappropriate rendering of English pages. So a solution may be to have different stylesheet files loaded per language. One way to come with this is to upload manually the stylesheets of the languages other than English into the public/journals/
jounal_id folder on the server and changing its name to
journalStyleSheet_ + code for loacale (e.g. es_ES, or fa_IR) + .css. Then we can add somthing to the TemplateManager.inc.php to read this style sheet instead of the main stylesheet. A sample code may be placed after:
- Code: Select all
// Assign stylesheet and footer
$journalStyleSheet = $journal->getSetting('journalStyleSheet');
such as:
- Code: Select all
$curLocExt = Locale::getLocale();
if ($curLocExt != "en_US") $journalStyleSheet['uploadName'] = str_replace("journalStyleSheet.css", "journalStyleSheet_{$curLocExt}.css", $journalStyleSheet['uploadName']);
Please visit the site of 'Journal of Research in Medical Sceicnes' to see a sample of separate sheets for each locale.
http://journals.mui.ac.ir/index.php/jrms
Regards,
Mahmoud