Re: Multi lingual pages
| From: | Otto Wyss | Date: | Fri, 26 Jan 2007 20:25:03 +0000 |
| Subject: | Re: Multi lingual pages | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-247849@lists.php.net to get a copy of this message | ||
Paul Novitski wrote:
I formulated my question in general since I couldn't find an other message here about supporting multiple languages.
http://www.w3.org/International/articles/ http://www.w3.org/TR/i18n-html-tech-lang/ http://php.net/setlocale Thanks a lot, these are good points for reading.
1) Switching language downloads a new version of the current page, generally with the same markup but new text. Example: http://partcon.ca/ I'll favor this way especially if several languages have to be provided.
In both cases I store the text in database tables that contain a language field I can select on to match the user's request. I wonder if retrieving static texts from the database draws too much performance. I know from somebody who stores texts in large data arrays an uses shared memory, yet I haven't figured it out how.I consider storing static texts as defines and just load a different definition file when the user switches language. Is this practical? O. Wyss