Hi all,
I want to change language changing in php. Suppose i want to change language from english to korean using php. How to use this in joomla CMS. I want to change total site changing into another language. I want to change that joomla site into multiple language. how? please help me.
Thanks & Regards,
Suresh
Converting language from english to korean?
Moderator: General Moderators
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
The usual way to do this (forgetting whatever Joomla does) is to make sure all textual parts of your website are loaded from language files then create some function to pull in the appropriate file:
Example directory structure
Example interface:
The language class would need to know something about the structure of your lang directory. It's probably best to load in the correct language in the controller rather than the view too.
Example directory structure
Code: Select all
./lang
./lang/en/
./lang/en/welcome1.txt
./lang/en/welcome2.txt
./lang/en/prices1.txt
./lang/fr/welcome1.txt
./lang/fr/welcome2.txt
./lang/fr/prices1.txtCode: Select all
<div class="something">
<?php echo Language::retrieve("welcome2", "en") ?>
</div>
...