[wp-trac] Re: [WordPress Trac] #7075: Issues with translating plugins

WordPress Trac wp-trac at lists.automattic.com
Mon Jun 2 15:12:07 GMT 2008


#7075: Issues with translating plugins
-----------------------+----------------------------------------------------
 Reporter:  msi08      |        Owner:  anonymous
     Type:  task       |       Status:  new      
 Priority:  normal     |    Milestone:  2.6      
Component:  General    |      Version:           
 Severity:  normal     |   Resolution:           
 Keywords:  has-patch  |  
-----------------------+----------------------------------------------------
Changes (by sambauers):

  * keywords:  => has-patch

Comment:

 There is a bug in that part of the implementation of #6938

 The fix for it is here http://trac.wordpress.org/attachment/ticket/6938
 /load_plugin_textdomain-fix.patch but not yet applied to trunk.

 After that fix, the behaviour will be more like before, but not exactly...

 If you don't specify the path in load_plugin_textdomain() it will work the
 same as before.

 The difference when you specify the path will be that the path should be
 relative to WP_PLUGIN_DIR.

 So for a plugin located in the standard plugin directory "wp-
 content/plugins/foo/foo.php" with language files at "wp-
 content/plugins/foo/lang" and a domain of "foo-domain" you would do
 this...

 {{{
 load_plugin_textdomain( 'foo-domain', dirname(plugin_basename(__FILE__)) .
 '/lang' );
 }}}

 Remember, this relies on that patch being applied to trunk.

-- 
Ticket URL: <http://trac.wordpress.org/ticket/7075#comment:2>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list