No Support => Feature requests => Topic started by: ivu on March 23, 2004, 10:04:56 am

Title: CPG in multiple languages?
Post by: ivu on March 23, 2004, 10:04:56 am
Hello all.

I was thinking about "multilanguage" photo gallery. I mean "multilanguage" pictures' title, description, comments, etc.
Since user can switch interface lang with "index.php?lang=english" - means that i can put buttons for different langs - it depends only on the theme.
I'm running CPG in Bulgarian language and I plan to allow aditional langs such as english, french, etc. But all titles and descriptins are in bulgarian and how english speaking users should read them? :-/ And what about comments? It will be total mess with so many comments in diff langs.

So here is my idea:
- additional multiple combobox (select) in config.php where the admin should select avaliable interface langs
for example the admin has selected english,french and bularian - the default lang is set in General settings. It will also require some db changes (i think so).
So, if there are more than 1 lang in the settings - on the main page appears icon (button) for each selected lang (and users can switch the lang by clicking them).

titles and descriptions:
When smone inserts an image on the top of the form will appear an drop-down with allowed languages and the default lang is selected by default. For example the default lang is english -> the user fills the fields title, description and keywords in english. If he wants to fill these fields in other language he must switch the drop-down. If he choose diff lang, the form clears these 3 fields (maybe some java script puts them into hidden field or som) and the user should fill the fields in the selected language. Maybe we will need additional table in the  db - for example cpg_pictures_details with 2 primary keys - picture_id and lang_id - and the columns title, description and keywords as well. So, we can inesrt into the db as many titles as we need for allowed langs. And when the script shows these details on the picture preview page - it will need only to filter where lang_id=interface lang (the lang which user has selected for the interface).

Here is my idea for the comments - the user should see comments only in the lang he has selected for the interface. We also need additional primary key in cpg_comments - lang_id. When the user adds a comment to an image - the script will insert automaticly the lang_id getting the lang that user has selected for the iface. So, english speaking users will not read the french comments for example.

I'm not familiar whit this stuff (that's only an idea) but that's the way i think it could be done.

I had an accident and my right arm is broken. After 2 months it will be ok and i think to try to make cpg "multilanguage" on my site.

Any suggestions or you think that this is a stupid idea?  :roll:
Title: CPG in multiple languages?
Post by: Joachim Müller on March 23, 2004, 10:14:18 am
afaik someone has already posted a mod to let you do this (at least part of it), please search the board.

Title: CPG in multiple languages?
Post by: Casper on March 23, 2004, 12:32:31 pm
It was posted by rbl, see this thread,