[Turned down]: Translation of content [Turned down]: Translation of content
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

[Turned down]: Translation of content

Started by johnwr, August 04, 2004, 01:26:06 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

johnwr

Hi

I would like to be able to translate the textcontent in my gallery (Categoryname, albumnames, descriptions, etc. etc., even comments.)

I've searched the forum, and found only one relevant previously thread:
 
Titles / descriptions in more than one language (http://forum.coppermine-gallery.net/index.php?topic=2121.0) originally created on 2003-12-03, 08:48:54

The thread provides some CSS hack for i.e. displaying picture descriptions according to selected language.

Gaugau says in that thread that this have been thought of by the dev team, but dropped due to lack of users needing this feature.
I for one am a user that would welcome it greatly.

Agreed, this would require a rewrite that is bigger than to be called a patch, but it might not be a major rewrite aither?
It's all a question of how much to put into it of course, but there is no need to make a complete CMS to achieve this on a simple level.

Now, I don't know any PHP, and can therefore not verify if my methods are appliable to coppermine. I am an experienced web programmer using Java, and might think differently than the dev team of coppermine.

To make this behaviour in coppermine we actually only need to create one new table, (again this is no CMS, only the simplest solution) and to modify the ones containing texts today.
I.e:
CREATE TABLE <prefix>_texts(
  textID INTEGER NOT NULL AUTO_INCREMENT,
  browsercode VARCHAR(5),
  textvalue TEXT,
  PRIMARY KEY (textID)
);
--The browsercode field should probably be abstracted into a languages table (or be maintained in a configfile), since a languageID is at least in my preference a lot more maintainable than a varchar thus being easier to work with for developers.

Then the existing tables with texts should be given a reference to this table:
ALTER TABLE <prefix>_categories ADD nameID INTEGER DEFAULT 0;
ALTER TABLE <prefix>_categories ADD descriptionID INTEGER DEFAULT 0;
and so on.

Then there have to be implemented a getTextvalue function in i.e. "functions.inc.php", with the textID and the requested languageID as parameters which returns a text.
This function should be supplemented by some language fallback function to ensure a result. (Check system default language, then english, than any?!?)

After this there's only the userfriendliness on how to input the texts, but I'm the opposite of an expert on that, being a programmer... ;-)

My preference in implementing websolutions is to put all (text)content in a database, and not in files. This feature request is of course based on that preference.
I know there are developers that disagrees with me, and I know this would generate some additional queries in some pages, thus slow coppermine a bit, but the latter would hardly be noticeable in my opinion.

I also know that this solution may sound simple, but may not be so to implement in coppermine.
Of course you competent members of the devteam have a lot of better solutions, but this is only meant as a starting point...

Hopefully there are more people than me that would welcome this feature, and that there are some developers that want to implement it for 1.4.

John

omniscientdeveloper

I wonder how reliable it would be to have the translation done by one of the web translators like altavista. It may not be exact, but it'll make it limit the amount of information that you'd have to store.

I'm sure there's some way to POST/scrape a web translator.


-omni

Joachim Müller

web translators are (like all machines doing translations) crap. Of course they can translate simple words like "cat" to french "chat", spanish "gato" or german "Katze", but as soon as they have to translate more than one word they miserably fail. This is caused by the way human language works, there's always a sub-context the human is able to understand and translate correctly, the machine never can do that. Automated translation will not work.

GauGau

Loïc

(if the question has already been asked somewhere else or if this already exists, accept my appologies, but I couldn't find anything searching "translation")

I would be very interested too in a hack that would allow, for example, to give both an english and a french title and description to every pict and an english and a french title to every categories and albums... Depending on the language choosen by the user, only the french or english stuffs would be shown...

I'm not a expert in php & MySql, but I think this could work without creating a new table, but only new fields in existing tables...

Thanx for ur help or ideas...

Slaven

I'm one more intereted in this feature, i think that would be great to have option to input text in diferent languages so it can be seen in languge choosen by client.
Any more info about this will be great. Greetings to all!

Pascal YAP

The previous Post just before your, is dated 24 dec 2005.
Not a rich idea to make an UP  ???

Slaven

THX for comment, maybe you have some fresh news or link (that would be better than s single date comment ;-) )

Joachim Müller

OK, actually this is a feature request that got turned down. There is no support in feature requests. Marking thread accordingly and locking. This means: sorry, no news. And probably there won't be any news on this.