CodeIgniter Forums
A Language File Translator - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forum-22.html)
+--- Thread: A Language File Translator (/thread-33974.html)



A Language File Translator - El Forum - 09-15-2010

[eluser]Jaap Jolman[/eluser]
Hello i made a new language translator

i used the google api
and some php functions

please leave any suggestions or comments

here is the readme

Author: Jacob Albert Jolman
Copyright: © ODIN-ICT 2010

USAGE:

// The language it's in now
$langfrom = "en"; // CHANGE TO THE LANGUAGE THE ORIGINAL FILES ARE IN
// The language you want to have it in
$langto = "nl"; // CHANGE TO THE LANGUAGE THE NEW FILES ARE IN

make sure the LANG directory is Write-able
and make a new dir with the new lang prefix
example:

nl

in the new directory make an new empty file with the name of the original file
example:

ORIGINAL

en
-> global_lang.php // has the original lang

NEW

nl
-> global_lang.php // new empty file that will be filled by the script

then run the script and it will fill the new file with the new language

Disclamer:
do not distribute without my premission;

======================================================================================

i made some change now you can translate the files without modifing the translator.php now you can use

http://YOUR SERVER/translator.php?from=en&to=nl

it will translate the files in the dir ./lang/en

to dutch and export it to the dir ./lang/nl

======================================================================================

install guide:

extract the files from translator.zip

and after you did that extract the files from translatorv0.2.zip and than replace the original translator.php with the one from the translatorv0.2.zip and then call translator.php?from=YOUR ORIGINAL LANG&to=YOUR LANG TRANSLATION

i found another bug

in some translation it uses " now it will be returned the rightway

extract the fix.zip over the old translator.php


A Language File Translator - El Forum - 09-15-2010

[eluser]Jaap Jolman[/eluser]
PLEASE REMOVE


A Language File Translator - El Forum - 09-15-2010

[eluser]Jaap Jolman[/eluser]
PLEASE REMOVE


A Language File Translator - El Forum - 09-17-2010

[eluser]Jaap Jolman[/eluser]
Please leave some comment


A Language File Translator - El Forum - 10-14-2012

[eluser]Unknown[/eluser]
Oh, I want these files Sad
I guess I could rewrite it myself, but would take a little time.