Pascal Opitz Blog: Quick helper script for ZF view translations

I have just published a note about Thomas Weidner working on creating single resource of Zend_Validate error message translations. There is one more useful tool for translators, this time from Pascal Opitz. Pascal has created a helper script that scans view files for untranslated messages and changes them into translate view helper calls.

Manual copy and paste jobs are a pain. Faced with the prospect of internationalizing 30+ big view files, I thought there had to be a better way. When I started to use the reg exp search facility in Textmate, the penny dropped. A helper script is what was needed.

As Pascal writes, his solution is not perfect, but it does the job and can be easily extended. It looks like nice addition to framework’s logging facility of not translated messages. Especially when one has to translate lots of files.



  • Share/Bookmark