4images Issues / Ausgaben > Feedback & Suggestions

A Suggestions for multi langual site



Thanks for the great job your are doing with 4images it is great one, but there is always the probleme with multilangual site I did try the sollution gave on the forum but it didnt work for :( anyways.. I have a little suggestion for exemple if some one want a multilanguage site he can active it from the adminstration section, and when he add a category he can give the name in the different language forr exemple :
Name of the Category in Database : Space

Traslation in English : Space
Translation in French : Espace

so the name of the category in the datebase will stay always space you dont have 2 create 2 category in the databse all you have to do is create one, and when you change the language it will directry get the information from the translations files
sorry for my english it is not that good...
Thanks for the Good job :)

Hello, all;
this feature already exists but not completely in 4images 1.7.4. Upload the language pack you need to use to your site.
Then type: http://www.your_site.com/your_gallery/index.php.l=spanish to get the interface displayed in spanish, for example.

In addition, V@no (whoelse?) did a MOD to have any text with multilanguage support here.

I have tested V@no's MOD here: http://amissc.free.fr/test/ and got entire satisfaction.
But there are many files to modify. I moded them all (I suppose and hope I had not forgotten anything) and posted them in a ZIP archive here for 4images 1.7.4 users.

You want to add your own text and have it multilingual compliant.
Lets say your text label is "Welcome" and its content is "Welcome to our site...Blah blah blah..."

* Open the file includes/page_header.phpFind:

--- Code: ---  "direction" => $lang['direction']
--- End code ---
and replace by:

--- Code: --- "direction" => $lang['direction'],
  "lang_welcome" => $lang['welcome'],  //we declare here the title
  "lang_welcome_text" => $lang['welcome_text']  //here we declare the welcome text
--- End code ---

You now have to insert the translation in each lang/language/main.php file.
Find, in main.php:

--- Code: ---//-----------------------------------------------------
//--- Paging ------------------------------------------
--- End code ---

and add just before:
english example:

--- Code: ---//-----------------------------------------------------
//--- Personnal texts ----------------------------------------
$lang['welcome'] = "Welcome";
$lang['welcome_text'] = "This is a welcome text";
--- End code ---

french example:

--- Code: ---//-----------------------------------------------------
//--- Textes persos ----------------------------------------
$lang['welcome'] = "Bienvenue";
$lang['welcome_text'] = "Ceci est un texte de bienvenue";
--- End code ---
...and so on with the several languages you use.

You can now insert in your HTML template files the tags {lang_welcome} and {lang_welcome_text} where you want them to be displayed, and keeping multilanguage support.
You also want to have header images or banner images including text translated when people click on a language flag.
Edit your image in your favourite image editor, and (sorry), make every translation needed. For instance, if your image is called "whatamess.jpg", containing your site slogan, edit it and custom in each language you need to use.
If you custom it in spanish, save it as "whatamess.jpg" in your_template/images_spanish/ folder.
If you custom it in french, save it as "whatamess.jpg" in your_template/images_french/ folder.
Then, insert it in your HTML template fie code:

--- Code: ---<img src="{template_lang_image_url}/whatamess.jpg" alt="" />
--- End code ---

The script will scan every language_images folder and display it, if only you have made a localized image.

A multilingual site is not just about coding. It involves research on which language to be used for the target market, localization options, how the apps will render in each language etc. The best thing is to rely on a professional language service agency who can combine human translation with machine learning to bring the best outcome. Read this to know what I am referring to https://www.mayflowerlanguages.com/multilingual-content-marketing-strategy/


[0] Message Index

Go to full version