Re: Multi lingual pages

From: Date: Mon, 19 Feb 2007 09:52:12 +0000
Subject: Re: Multi lingual pages
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-249012@lists.php.net to get a copy of this message
Jochem Maas wrote:
don't go down the define('LANG_KEY', 'lang string value'); route - defines are comparatively SLOW to create. IF you go down the road of loading in text from 'per lang' files I would suggest using an array as the storage mechanism: $Lang = array( 'LANG_KEY' => 'lang string value', // .. etc ); assoc array are much less heavy to create. Thanks, I'll try the assoc array.
also consider that there are, imho, 2 kinds of language specific data: 1. 'static' values - button texts, [error] messages - these are specified during site/application design. Yes these are the static texts I'm talking about. They don't depend on data, only on layout and design.
2. 'dynamic' values - document titles, headers, content - these are specified by the owner/user during the lifetime of the site/application Sure, I've these values too and store them in the database.
for the rest I'll just say 'ditto' to most of what the other list members replied :-) Thanks a lot.
O. Wyss

« previous php.general (#249012) next »