0
votes

I would like to ask for suggestions on implementing localization in codeigniter. The problem that I'm facing now is I need to localize the site's copies/contents. It may sound simple but what if I needed to localize a whole article,with html tags and css, to 9 diff languages?

I've already considered using the localization feature of CI and i don't think it is a good solution to this kind of localization. Also, I'm not considering to use a database for contents.

Can you please share your thought/technique/approach that you used for this problem? Thanks in advance!

1

1 Answers

0
votes

According to your question, you don't want to maintain the content for each language in datatabase.

Also, I'm not considering to use a database for contents.

Google is providing website translator code snippet. This is very simple solution.

Log into google account and access this url https://translate.google.com/manager/website/add?site=72a62c4cacb71063

They asked your website URL and there you can choose the language which you are want and generate the script (javascript code).

Copy and paste that code snippets onto every page you want to translate.

For demo: Go to Gmail login page and change the language using dropdown (in footer section)