Hi!
I have been in contact with Garvin Hicking regarding a blog-system he is a developer of(www.s9y.org). I originally contacted him to offer a contribution to that project. The contribution was a php-script to manage the languagefiles of their blogsystem. I originally created the script for my own CMS solution. Both my and their languagefiles used constants for storing translated text.
He told me that you may be interested in using this for phpMyAdmin, since I use phpMyAdmin everyday I thought maybe I could contribute a bit to you too. I adapted the code to your string-based languagefiles. So now it works with phpMyAdmin.
The tool has these features: - Online updating trough a web-browser. - Remember last language you worked with. - Login via htpasswd-files (can be changed to MySQL with great ease) - Download all, or single files as zip. (do not require user to enter username / password) - List all available languages for download. (do not require user to enter username / password) - Automatic detection of correct container for strings. (example: if string contains \n the string will be contained within , if no special chars are detected the string is contained within ) - Support multiple charsets, and sets the HTTP-header charset to the correct charset. (required by phpMyAdmins languagefiles).
I am open to suggestions on more features...
I think this app will make it more comfortable for your translators to translate. You will be able to change from strings to constants (or any other format) in your languagefiles without worrying about users not being able to translate the new files. Users of phpMyAdmin will be able to download languagefiles whenever they want. It will be easier for a new translator to get started translating a new language.
You may test the script/app at http://demo.prosjektweb.net/languageadmin/phpmyadmin.php login with username: s , password: s To view available languages for download go to : http://demo.prosjektweb.net/languageadmin/phpmyadmin.php?m_action=show_files
So I guess my question is do you want to use this app?
Mvh Martin Kronstad Siteman AS www.siteman.no Telefon: 32 87 56 10 Mobiltelefon: 951 70 230 Telefaks: 61 13 16 51
Hi
On Wed, 11 Jan 2006 13:00:50 +0100 Martin Kronstad martin@siteman.no wrote:
You may test the script/app at http://demo.prosjektweb.net/languageadmin/phpmyadmin.php login with username: s , password: s To view available languages for download go to : http://demo.prosjektweb.net/languageadmin/phpmyadmin.php?m_action=show_files
So I guess my question is do you want to use this app?
I looks great! However I noticed it doesn't handle correctly arrays we use for some stuff (byte units, days of week and months).
How does it store updated messages?
You may test the script/app at http://demo.prosjektweb.net/languageadmin/phpmyadmin.php login with username: s , password: s To view available languages for download go to :
http://demo.prosjektweb.net/languageadmin/phpmyadmin.php?m_action=show_file s
So I guess my question is do you want to use this app?
I looks great! However I noticed it doesn't handle correctly arrays we use for some stuff (byte units, days of week and months).
How does it store updated messages?
-- Michal Čihař | http://cihar.com
Hi!
I actually meant to support arrays, I must have forgotten to make the code, however it will support arrays.
I'm not sure if I understood your question about how it stores the new messages but.
How it stores files:
When the app returns from when the user has submitted the form, the file is parsed again, if the function detects a _REQUEST field with the same name as a key in the file, the value for the key is changed to the value of _REQUEST[$key]. Then it adds a line to a variable that holds the entire file.
When the file has been parsed a the file is saved. The form then uses an internal array containing the new messages. So the user actually just sees his own _REQUEST feedback, while the file is written.
I made it this way so I could have the same code for saving as I have for file parsing. Less code to maintain. I guess I could optimize the code a bit by adding a handler for the form-submit. But this way I also protect against people adding new keys to the file.
Anyone who wants to take a look at the code please see http://demo.prosjektweb.net/languageadmin/langadmin.tar.gz
Mvh Martin Kronstad Siteman DA www.siteman.no
Telefon: 32 87 56 10 Mobiltelefon: 951 70 230 Telefaks: 61 13 16 51
Hi!
Just wanted to say, that it now supports arrays, it divides up the arrayitems with a named divider (for now #:#), however it is possible to configure this.
The source at http://demo.prosjektweb.net/languageadmin/langadmin.tar.gz is updated with the one supporting arrays.(The online demo is also updated)
Is there any interest for using this app with phpMyAdmin?
Mvh Martin Kronstad Siteman DA www.siteman.no
Telefon: 32 87 56 10 Mobiltelefon: 951 70 230 Telefaks: 61 13 16 51
-----Opprinnelig melding----- Fra: phpmyadmin-devel-admin@lists.sourceforge.net [mailto:phpmyadmin-devel-admin@lists.sourceforge.net] På vegne av Martin Kronstad Sendt: 11. januar 2006 14:43 Til: phpmyadmin-devel@lists.sourceforge.net Emne: SV: [Phpmyadmin-devel] Re: Translation tool for phpMyAdmin's string-based languagefiles.
You may test the script/app at http://demo.prosjektweb.net/languageadmin/phpmyadmin.php login with username: s , password: s To view available languages for download go to :
http://demo.prosjektweb.net/languageadmin/phpmyadmin.php?m_action=show_file s
So I guess my question is do you want to use this app?
I looks great! However I noticed it doesn't handle correctly arrays we use for some stuff (byte units, days of week and months).
How does it store updated messages?
-- Michal Čihař | http://cihar.com
Hi!
I actually meant to support arrays, I must have forgotten to make the code, however it will support arrays.
I'm not sure if I understood your question about how it stores the new messages but.
How it stores files:
When the app returns from when the user has submitted the form, the file is parsed again, if the function detects a _REQUEST field with the same name as a key in the file, the value for the key is changed to the value of _REQUEST[$key]. Then it adds a line to a variable that holds the entire file.
When the file has been parsed a the file is saved. The form then uses an internal array containing the new messages. So the user actually just sees his own _REQUEST feedback, while the file is written.
I made it this way so I could have the same code for saving as I have for file parsing. Less code to maintain. I guess I could optimize the code a bit by adding a handler for the form-submit. But this way I also protect against people adding new keys to the file.
Anyone who wants to take a look at the code please see http://demo.prosjektweb.net/languageadmin/langadmin.tar.gz
Mvh Martin Kronstad Siteman DA www.siteman.no
Telefon: 32 87 56 10 Mobiltelefon: 951 70 230 Telefaks: 61 13 16 51
------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37&alloc_id%16865&op=ick _______________________________________________ Phpmyadmin-devel mailing list Phpmyadmin-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/phpmyadmin-devel
Martin Kronstad a écrit :
Hi!
Just wanted to say, that it now supports arrays, it divides up the arrayitems with a named divider (for now #:#), however it is possible to configure this.
The source at http://demo.prosjektweb.net/languageadmin/langadmin.tar.gz is updated with the one supporting arrays.(The online demo is also updated)
Is there any interest for using this app with phpMyAdmin?
Hi,
yes, there is interest, thanks. I'll have a look as time permits, sorry.
Marc Delisle
Hi
On Wed, 11 Jan 2006 21:51:37 +0100 Martin Kronstad martin@siteman.no wrote:
Just wanted to say, that it now supports arrays, it divides up the arrayitems with a named divider (for now #:#), however it is possible to configure this.
The source at http://demo.prosjektweb.net/languageadmin/langadmin.tar.gz is updated with the one supporting arrays.(The online demo is also updated)
Thanks, I will check it during weekend.
Is there any interest for using this app with phpMyAdmin?
Yes there definitely is. I already started discussion on using on-line translating system some time ago and there was quite positive feedback from translators, so the only question that remains is how to integrate this tool with our current work style. We currently allow only official translators to update language files to ensure some quality - we do not know all languages and it's easy for someone anonymous to write something naughty into some message and we won't notice that translation of Welcome string to Chinese says for example fuck you all.
So to integrate with our current practice, I would suggest following:
- allow of upload of whole file (in case translator wants to put his version into system) - ability to merge with cvs, I guess this could be done by cvs + some shell scripting executed daily from cron - send emails to translators with changes before release so that they can review changes and possibly upload them to translation tracker
Comments?
Michal Čihař wrote:
Is there any interest for using this app with phpMyAdmin?
Yes there definitely is. I already started discussion on using on-line translating system some time ago and there was quite positive feedback from translators, so the only question that remains is how to integrate this tool with our current work style. We currently allow only official translators to update language files to ensure some quality - we do not know all languages and it's easy for someone anonymous to write something naughty into some message and we won't notice that translation of Welcome string to Chinese says for example fuck you all.
So to integrate with our current practice, I would suggest following:
- allow of upload of whole file (in case translator wants to put his
version into system)
- ability to merge with cvs, I guess this could be done by cvs + some
shell scripting executed daily from cron
- send emails to translators with changes before release so that they
can review changes and possibly upload them to translation tracker
How do mean the system should merge the documents, should the system read the file in cvs and replace everything that exist in the languagefile, then download a new copy from cvs?
I have a idea of how to mark new keys fetched from CVS. Why not add a comment on each string when adding a new key to the languagefiles in CVS?
(strSomeTranslatedString is translated and not new but $strSomeOtherString has been fetched/merged from files in CVS) (example code) $strSomeKeyStringName = 'This text has not yet been translated'; // MISSING $strSomeOtherString = 'This should be translated'; // MISSING $strSomeTranslatedString = 'Denne strengen er oversatt'; (end example code)
Then the system can read every string with "// MISSING", and tell the translator that this is a key that has not been translated since the key was fetched from cvs. (This way the system could also list only the strings witch is marked as missing in the form).
This way we could email the language translators whenever we want. We could also show how much of the language has been translated. Another good thing is that we could filter out all new strings, so the translators do not have to search for new strings...
(I will start working on the upload-feature)
BR Martin Kronstad
Hi
sorry I still lack time to look at your code...
On Fri, 13 Jan 2006 17:59:05 +0100 Martin Kronstad martin@siteman.no wrote:
How do mean the system should merge the documents, should the system read the file in cvs and replace everything that exist in the languagefile, then download a new copy from cvs?
I have a idea of how to mark new keys fetched from CVS. Why not add a comment on each string when adding a new key to the languagefiles in CVS?
(strSomeTranslatedString is translated and not new but $strSomeOtherString has been fetched/merged from files in CVS) (example code) $strSomeKeyStringName = 'This text has not yet been translated'; // MISSING $strSomeOtherString = 'This should be translated'; // MISSING $strSomeTranslatedString = 'Denne strengen er oversatt'; (end example code)
Then the system can read every string with "// MISSING", and tell the translator that this is a key that has not been translated since the key was fetched from cvs. (This way the system could also list only the strings witch is marked as missing in the form).
This is similar to //to translate, I don't think we have to introduce new comment.
What I meant was to incorporate correctly changes that happen in CVS. There might be some conflicting translations ... Hmmm in this case it is probably okay to prefer CVS version.
This way we could email the language translators whenever we want. We could also show how much of the language has been translated.
This is already done - http://www.cihar.com/phpMyAdmin/stats/translations.php
Another good thing is that we could filter out all new strings, so the translators do not have to search for new strings...
They should IMO look for untranslated rather than for new.
Hi
sorry I still lack time to look at your code...
No problem :)
This is similar to //to translate, I don't think we have to introduce new comment.
Ok
What I meant was to incorporate correctly changes that happen in CVS. There might be some conflicting translations ... Hmmm in this case it is probably okay to prefer CVS version.
I'll have a look at the files in CVS as soon as I can ... I too have some timeproblems right now...
This is already done - http://www.cihar.com/phpMyAdmin/stats/translations.php
Ok