Welcome Guest, please login or register.
Username:
Password:

News: Welcome to Hostpapa Forums!
Pages: [1]   Go Down
Topic Tools  
Read
March 12, 2009, 06:36:20 PM
sbdrs
Newbie
*
Posts: 2



I have created a unilingual site, in English, however I now need to have the same site but in French. What is the best way to do this? Or how is this done?
Logged
 

Read
March 13, 2009, 08:12:40 AM
wspeeckaert
Jr. Member

**
Posts: 94



I created a site at http://www.skinetcanada.ca that is fully bilingual. I use a php file that has an array of French and English terms- here is an example

$terms['E']['hello']='Hello';
$terms['F']['hello']='Bonjour';
$terms['E']['alpine']='Alpine';
$terms['F']['alpine']='Alpin';

I include this file in all the site php files

I also use cookies to remember the preferred language in a variable named $language; then whenever I need a particular language I just write the following:

echo $terms[$language]['hello'];// the $language variable must have been initialized to 'E' or 'F'.

You could could use same the same technique for other languages as well.

Another option is to use a mysql table to hold the translations.

This method only work though if you have a site that is mostly numbers. If you have a lot of text; you could simple start all English files with an E_ and all French files with an F_ and then use AJAX and javascript to load the appropriate file.
« Last Edit: February 03, 2011, 07:14:26 AM by wspeeckaert » Logged
 

Read
July 12, 2009, 10:41:25 AM
ZenStudios
Newbie
*
Posts: 4



Hi wspeeckaert,
Isn't there a file that holds all the default english terms used in a template? Say, if I have an "about" page, a "products" page, a "services" page ... wouldn't the terms (in quotation marks) for the template be held a a specific file or db somewhere? How do I know that I have created each and every terms within the template into the second language?

Thanks for your help
Logged
 

Read
July 12, 2009, 07:24:34 PM
wspeeckaert
Jr. Member

**
Posts: 94



I guess that would depend on the software you use. Since I create my own pages and write my own routines, I haven't used any site management software. I wrote my own.

I know a lot of free web packages come with resource files for different languages.
Logged
 

Read
July 13, 2009, 09:56:51 AM
ZenStudios
Newbie
*
Posts: 4



I have created a unilingual site, in English, however I now need to have the same site but in French. What is the best way to do this? Or how is this done?

Hi, Within you Soholaunch admin tool you need to get into the database tables, from there you need to go into the systems table and change the data there. Make sure to make a Back-up before you alter the original file
Hope that helps!
Logged
 

Read
August 24, 2010, 03:43:32 AM
chenchen21621
Newbie
*
Posts: 3



Hi wspeeckaert,
Isn't there a file that holds all the default english terms used in a template? Say, if I have an "about" page, a "products" page, a "services" page ... wouldn't the terms (in quotation marks) for the template be held a a specific file or db somewhere? How do I know that I have created each and every terms within the template into the second language?

Thanks for your help


« Last Edit: August 25, 2010, 02:52:59 PM by Adam » Logged
 

Read
August 24, 2010, 06:43:35 AM
wspeeckaert
Jr. Member

**
Posts: 94



I don't use templates- I design all my sites. For bilingual sites I use an array with the English and French term.
Logged
 

Read
September 04, 2010, 11:52:06 PM
dina2189
Newbie
*
Posts: 1



I guess that would depend on the software you use. Since I create my own pages and write my own routines, I haven't used any site management software. I wrote my own.
Logged
 

Pages: [1]   Go Up
Jump to:  

Theme by webtechnica.net