<div>Always use a string.. Don't use a variable, Don't use a Constant.<br></div><div><br></div><div>Gettext applications look at the php files as an onlooker, It can't tell what the contents of $lang is, it can't tell the contents of CONSTANT_MY_LANG, It just knows the first param is a string, and the second is the text domain for it. It's basically the same as running a regex over an unknown string, or scanning through a French document looking for the word which comes after XYZ..</div>
<div><br></div><div>When you're generating a .pot file from a single theme/plugin, you can specify the text domain you want the resulting file to use.. when you're automating translations for thousands of items (like WordPress.org will do one day..) then you can't guess.. the authors need to be specific for maximum compatibility!</div>
<div><br></div><div>Does that help at all Chip? :)</div><div><br></div><div><br></div><div class="gmail_quote">On 6 October 2011 23:23, Chip Bennett <span dir="ltr"><<a href="mailto:chip@chipbennett.net">chip@chipbennett.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Thanks for passing this along, Mike!<div><br></div><div>There seems to be some discussion/disagreement in the comments and via Twitter. What's the consensus?</div>
<div><br></div><div><font color="#888888">Chip</font><div><div class="h5"><br><br><div class="gmail_quote">
On Thu, Oct 6, 2011 at 1:24 AM, Michael Fields <span dir="ltr"><<a href="mailto:michael@mfields.org" target="_blank">michael@mfields.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hello!<br>
<br>
This just came through my Twitter feed:<br>
<a href="http://markjaquith.wordpress.com/2011/10/06/translating-wordpress-plugins-and-themes-dont-get-clever/" target="_blank">http://markjaquith.wordpress.com/2011/10/06/translating-wordpress-plugins-and-themes-dont-get-clever/</a><br>
<br>
Thought it might make a pretty good addition to the requirements.<br>
It also might be a pretty easy check to work into the Theme Check plugin.<br>
<br>
I'm guilty of this myself in plugins and think that's it's really great to have an explanation of why this is wrong :)<br>
<br>
Just wanted to pass it along!<br>
<br>
- Mike<br>
_______________________________________________<br>
theme-reviewers mailing list<br>
<a href="mailto:theme-reviewers@lists.wordpress.org" target="_blank">theme-reviewers@lists.wordpress.org</a><br>
<a href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers" target="_blank">http://lists.wordpress.org/mailman/listinfo/theme-reviewers</a><br>
</blockquote></div><br></div></div></div>
<br>_______________________________________________<br>
theme-reviewers mailing list<br>
<a href="mailto:theme-reviewers@lists.wordpress.org">theme-reviewers@lists.wordpress.org</a><br>
<a href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers" target="_blank">http://lists.wordpress.org/mailman/listinfo/theme-reviewers</a><br>
<br></blockquote></div><br>