perl.i18n...Re: Perl, setlocale and Apache by Claude Paroz- May 15, 2006 Le samedi 13 mai 2006 à 23:02 +0200, Claude Paroz a écrit :> Hi,> > I&39;m trying to localise some web pages written with Perl scripts.> Here is a sample script I&39;m using to test :> > !usrbinperl> use CGI qw(:all);> use Locale::gettext;> use POSIX;> > POSIX::setlocale(LC_MESSAGES, "fr");> textdomain "libc";> > my $q = new CGI;> print $q->header;> print $q->start_html(-title=>"Admin...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg185.html Perl, setlocale and Apache by Claude Paroz- May 13, 2006 Hi,I&39;m trying to localise some web pages written with Perl scripts.Here is a sample script I&39;m using to test :!usrbinperluse CGI qw(:all);use Locale::gettext;use POSIX;POSIX::setlocale(LC_MESSAGES, "fr");textdomain "libc";my $q = new CGI;print $q->header;print $q->start_html(-title=>"Admin Login");print $q->p(gettext("write incomplete"));print $q->end_html;If I run the script in the command line (perl test.pl), I&39;m getting...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg184.html RE: ordering Japanese by Mike Barborak- May 6, 2006 For posterity, I want to be sure that Barry&39;s reply below gets into themailing list archive. - Mike Mike -That is generally the way these things proceed, but even that is stillintractable.1: Some namesplaces my have multiple readings2: The correct reading may not be known to the typist3: Taking the reading from the IME input doesn&39;t work either, because, I amtold, that many Japanese will type a shorter reading for the Kanji, maybeeven one that doesn&39;t make sense, in order to save...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg183.html Re: ordering Japanese by Kino- May 5, 2006 Sorry, wrong editing in my previous message. KinoOn 6 May 2006, at 0:33, Kino wrote:> Usually it is called &x8AAD;&x307F; (yomi). It would be better to let > them enter not only the yomi of a company name (e.g. &x3055;&x304F;&x3089;&x306E; > &x3072;&x3083;&x3063;&x304B;&x3066;&x3093; for &x3055;&x304F;&x3089;&x91CE;&x767E;&x8CA8;&x5E97;) but also that of the > place name (e.g. &x305B;&x3093;&x3060;&x3044; for &x4ED9;&x53F0;), I think. <Or what > do you>Incomplete...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg182.html Re: ordering Japanese by Kino- May 5, 2006 On 5 May 2006, at 23:19, Mike Barborak wrote:> Second, to answer Kino&39;s question - I&39;m not sure what the input > method is other than to say the Japanese is being submitted via a > form on a UTF-8 web page. My input method has been to cut and paste > from other UTF-8 sources - hmmm. But in other words, I don&39;t have a > hook into that part of the process.Now I understand the situation.> Third, so the solution seems to be that I will have the content > editors...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg181.html RE: ordering Japanese by Mike Barborak- May 5, 2006 First, let me thank everyone for their help - this is tremendous as now Iunderstand I am trying to solve a practically indeterminate problem. Thiswhole project has been a great learning experience - very cool stuff.Second, to answer Kino&39;s question - I&39;m not sure what the input method isother than to say the Japanese is being submitted via a form on a UTF-8 webpage. My input method has been to cut and paste from other UTF-8 sources -hmmm. But in other words, I don&39;t have a hook into...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg180.html Re: ordering Japanese by Barry Caplan- May 5, 2006 Ah! A non-Japanese speaker :)Japanese is probably the world&39;s most complex writing system.It is a pretty safe bet that almost all kanji have more then onepronunciation - the actual reading is very context dependent.The only algorithm that is going to work is "brute force" and even then,especially with names, I bet you won&39;t cover everything. I recallmeeting a Japanese translator whose thesis showed that even Japanesephone operators have something like (IIRC) a 70% chance of...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg179.html Re: ordering Japanese by Kino- May 4, 2006 On 5 May 2006, at 13:16, Kino wrote:> On 4 May 2006, at 8:12, Mike Barborak wrote:>>> If so does anyone know of a Perl module to do this or a nice >> reference that I could use more programmatically than the image on >> the link above>> I don&39;t know and I&39;m afraid there&39;s not such a module. To give a > pronunciation to all common kanji words would require a large > dictionary...but we should be able to create a conversion script from dictionaries.http://www.nntp.perl.org/group/perl.i18n/2006/05/msg178.html Re: ordering Japanese by Kino- May 4, 2006 On 4 May 2006, at 8:12, Mike Barborak wrote:> Here is an example of 13 store names ordered with> Lingua::JA::Sort::JIS::msort:>> 1. &x4F0A;&x52E2;&x4E39;&x3000;JR&x4EAC;&x90FD;&x5E97;> 2. &x30A2;&x30DA;&x30C3;&x30AF;&x30B9;&x3000;&x798F;&x5C71;> 3. &x30A2;&x30DF;&x30E5;&x30D7;&x30E9;&x30B6;&x3000;&x9E7F;&x5150;&x5CF6;> 4. &x30AA;&x30AF;&x30CE;&x3000;&x65ED;&x5DDD;> 5. &x3055;&x304F;&x3089;&x91CE;&x767E;&x8CA8;&x5E97;&x3000;&x4ED9;&x53F0;> 6....http://www.nntp.perl.org/group/perl.i18n/2006/05/msg177.html RE: ordering Japanese by Mike Barborak- May 4, 2006 Thanks for the reply. And yes, that&39;s the explanation that I got from myclient - that the ordering should be based on the pronunication of theJapanese and then based on this ordering:A I U E OKa Ki KuQu Ke Ko (Ca Ci Cu Ce Co if the sound is "K")Ga Gi Gu Ge GoSa Shi Su Se So (Ca Ci Cu Ce Co if the sound is "S")Ja Ji Ju Je JoZa Zi Zu Ze ZoTa Ti Tu Tsu Te ToDa Di Du De DoNa Ni Nu Ne NoHa Hi Hu He HoVa Vi Vu Ve VoPa Pi Pu Pe PoFa Fi Fu Fe FoBa Bi Bu Be BoMa Mi Mu Me MoYa Yi...http://www.nntp.perl.org/group/perl.i18n/2006/05/msg176.html |