2014-02-12 23:40
浏览 65

用于PHP Gettext字符串的字符串处理软件

Currently I'm in a major project which has several thousands of PHP gettext like translations

_("blabla I'm an English source file")

These lines will be translated with PO Files generated by PO Edit. However, we have an english gammer nazi which is going to check all of our grammar and correct spelling mistakes. However the grammer nazi is not really into coding and it would be nice to have a large list with all the __("blabla") strings.

So basically I'm looking for a tool which can read all my PHP Files (much like PO edit) and make it a readable list that can be edited and saved (back to the PHP files).

Is there such a tool? Or am I doomed and do I create it myself?

I prefer OSX since were all using it here, but something windowsish would be fine.

图片转代码服务由CSDN问答提供 功能建议

目前,我正处于一个拥有数千个PHP gettext的主要项目中,如翻译 \ n


这些行将使用PO编辑生成的PO文件进行翻译。 但是,我们有一个英语gammer纳粹语,它将检查我们所有的语法和纠正拼写错误。 然而,语法纳粹并没有真正进入编码,拥有一个包含所有 __(“blabla”)字符串的大型列表会很不错。

所以基本上 我正在寻找一个可以读取所有PHP文件的工具(很像PO编辑),并使其成为一个可编辑和保存的可读列表(返回PHP文件)。

有这样的工具吗? 或者我注定要自己创建吗?


  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • ds0678 2014-02-13 08:03

    I would just use English like you use your other translations and create a po file for it. This way your English grammer person can also change whole sentences now and later without actually affecting the code. And you can at some point add different english versions (e.g. en-US, en-GB).

    打赏 评论
  • doufeng1249 2014-02-12 23:51

    How about the xgettext util described here.

    打赏 评论

相关推荐 更多相似问题