[wp-hackers] Plugin Language Translation

Computer Guru computerguru at neosmart.net
Sun Mar 25 14:17:46 GMT 2007


You can use Komodo or GREP to add it in with a regex replacement search....
make things easier :)

Computer Guru
NeoSmart Technologies
http://neosmart.net/blog/

> -----Original Message-----
> From: wp-hackers-bounces at lists.automattic.com [mailto:wp-hackers-
> bounces at lists.automattic.com] On Behalf Of Andy Staines
> Sent: Sunday, March 25, 2007 3:18 PM
> To: wp-hackers at lists.automattic.com
> Subject: Re: [wp-hackers] Plugin Language Translation
> 
> Alex Günsche wrote:
> > On Sun, 2007-03-25 at 13:41 +0100, Andy Staines wrote:
> >
> >>>> Absolutely. Thanks for taking a look. I have zipped them up and
> they are at:
> >>>> Download mo-po <http://www.yellowswordfish/downloads/French-mo-po-
> files.zip>
> >>>>
> >
> > Ok, the problem is, as far as I see, that you do not provide the
> > textdomain to use to the WP function __(). For example, you have the
> > code
> >
> > __("Forum Locked")
> >
> > but when you use the textdomain "simple-forum", it should read
> >
> > __("Forum Locked", "simple-forum")
> >
> > You mentioned that some words actually were translated, I assume they
> > are words that are contained in the global language file (e.g.
> "Posts").
> >
> > By the way, in your beta, the filename is simple-forum-FR_fr.mo,
> while
> > it should read simple-forum-fr_FR.mo as this is the correct and usual
> > locale token. And, you should use the API hook "init" for loading the
> > textdomain, because this ensures that multilinguality plugins such as
> > Polyglot will choose the correct language.
> >
> > HTH
> >
> > Regards,
> > Alex
> >
> >
> A million thanks Alex
> There is conflicting advice on the codex regarding the __() format. One
> said you required the text domain the other did not include it and I
> thought the one without was the more recent article so I used that. I
> will add that in... 419 times! and also do the other tasks you have
> given me.
> I am very grateful for this help. I will inform the young lady in
> France
> she can finish the task!
> 
> Regards
> Andy
> 
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers



More information about the wp-hackers mailing list