This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
multilingual_sites [2018/02/25 08:54] admin [Multilingual Sites] |
multilingual_sites [2018/02/25 08:54] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | |||
+ | ====== Multilingual Sites ====== | ||
+ | |||
+ | |||
+ | It's pretty easy to create a multilingual site. | ||
+ | |||
+ | First of all, open Rotation Settings, | ||
+ | |||
+ | Since this moment you'll ba able t edit descriptions for each gallery in each language. | ||
+ | |||
+ | An easy way to create links is to have following lines in you .htaccess file | ||
+ | |||
+ | < | ||
+ | RewriteBase / | ||
+ | RewriteCond %{REQUEST_FILENAME} !-f | ||
+ | RewriteCond %{REQUEST_FILENAME} !-d | ||
+ | RewriteRule ^([^/ | ||
+ | </ | ||
+ | |||
+ | and links like http:// | ||
+ | |||
+ | but feel free to modify links and rewrite in anyway. | ||
+ | |||
+ | |||
+ | ====== Categories and galleries ====== | ||
+ | |||
+ | You can edit language data for each category and galleries. | ||
+ | Note, that you have some options here: you can have just translations, | ||
+ | |||
+ | ====== Site Internationalization (i18n) ====== | ||
+ | |||
+ | If you also want to translate site's menu you can do the following | ||
+ | |||
+ | 1. create custom template , let's say languages | ||
+ | < | ||
+ | <? | ||
+ | $my_keywords[' | ||
+ | ' | ||
+ | ' | ||
+ | and so on | ||
+ | ); | ||
+ | |||
+ | $my_keywords[' | ||
+ | ' | ||
+ | ' | ||
+ | and so on | ||
+ | ); | ||
+ | |||
+ | and so on as many languages as you want | ||
+ | |||
+ | |||
+ | |||
+ | if ($_GET[' | ||
+ | $lang = $my_keywords[$_GET[' | ||
+ | } else $lang = $my_keywords[$_GET[' | ||
+ | |||
+ | That's it. | ||
+ | As you can see here if you have & | ||
+ | </ | ||
+ | |||
+ | 2. In each template, where you need any translations add | ||
+ | |||
+ | < | ||
+ | < | ||
+ | </ | ||
+ | |||
+ | |||
+ | 3. in templates replace actual phrases with variables | ||
+ | < | ||
+ | Most popular => <? | ||
+ | Order By Date => <? | ||
+ | and so on | ||
+ | </ | ||
+ | |||
+ | So at this point you should see translations if you open let's say index page as http:// | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||