There are many paths to the same goal :-)
Hope you find your solution.
Langdon
peper wrote:
Well. Your idea looks good.
For me caching and language selection is done in flash. On the other
hand, this solution looks hard to put into our CMS. I'll think about
it.
Thank you for your help.
I had the same problem in my last project, a multilanguage product
katalog:
http://www.shop.werit.eu
My solution was like langdon proposed:
a table called languages which keeps all translated strings and hold a
reference to the related record:
- id
- object_id (foreign object)
- lang
Thanks.
I read about i18n and PEAR::Translation2 packages, and I even found a
cake component to use it. But it's not what I need.
This all is about static content like menus, titles etc. For static
content I can use built-in flash mechanism and this is not a problem.
The problem is for dynamic
products table: add language_id.
for language detection add lang in URl,
like: products/view/en/123... or somethin else.(so page could be
linked)
grab this lang, find language id and select from products where
language:id
put language_id in session etc.
This is not CAKE feature, but general
Hi peper
Your situation is similar to mine. My solution is for a product would
be, store a reference to the appropriate text string instead of a field
of text in the product record.
So you have one description field that holds a key for the string (and
all of its translations)
Store the
Hi majna
As you say, this isn't about Cake, its just a PHP design patern.
What you suggested is pretty much what I do, except that I get the
language setting from the browser. To allow me to cache views though I
will need to do as you are suggesting and add the language to the URL.
Langdon
Hi. I'm developing a Flash site using CakePHP+AMFPHP as a server back-
end. The site will be multilingual. What would You suggest to do this?
I think of making DB like that, for example
Product (id, name, descriptionEN, descriptionFR, descriptionPL, image)
it is easy to manage for web admin.
Hi peper
Hi. I'm developing a Flash site using CakePHP+AMFPHP as a server back-
end. The site will be multilingual. What would You suggest to do this?
I am working on a site with this requirement too. My solution:
I Googled PHP i18n solutions. I now have a function that is similar to
the