MooseReiver
09-15-2008, 08:17 PM
I wanted to add small flag icons in the navigation section to switch between English and German. The template files are named like "about_DE_template.html". (I chose to use uppercase language codes.)
-Add flag icons to the language directory.
-In the navigation section of the templates, add:
<a href="?lang=DE" title="Deutsch"><img src="language/Deutsch.gif" border=0> </a>
<a href="?lang=EN" title="English"><img src="language/English.gif" border=0> </a>
-Since I used uppercase language codes, I had to edit line 181 to remove the strtolower() function:
$default_language_abr = $PP_supp_lang[$cfgrow['langfile']][0];
Now, by clicking on a flag, the language preference is quickly changed.
See it at: http://www.randalcarr.com/rc/photoblog/index.php
-Add flag icons to the language directory.
-In the navigation section of the templates, add:
<a href="?lang=DE" title="Deutsch"><img src="language/Deutsch.gif" border=0> </a>
<a href="?lang=EN" title="English"><img src="language/English.gif" border=0> </a>
-Since I used uppercase language codes, I had to edit line 181 to remove the strtolower() function:
$default_language_abr = $PP_supp_lang[$cfgrow['langfile']][0];
Now, by clicking on a flag, the language preference is quickly changed.
See it at: http://www.randalcarr.com/rc/photoblog/index.php