我正在尝试使用 cake 2.3 使用 cake 的 i18n shell 从我的网站生成 pot 文件。正如蛋糕文档中提到的,shell 应该自动提取验证消息。但是,我的 pot 文件中没有出现任何验证字符串。
我的验证数组看起来就像这样(另请注意validationDomain):
public $validationDomain = 'validation_errors';
public $validate = array(
'currency' => array(
'notempty' => array(
'rule' => array('notempty'),
'message' => 'Select a currency'
),
),
'title' => array(
'notempty' => array(
'rule' => array('notempty'),
'message' => 'Fill out a title'
),
)
... etc
)
我在这里没有看到什么?!
谢谢分配!
最佳答案
在应用程序中使用它,而不是在/app/Console 中
cake.bat i18n extract
关于shell - cakephp i18n shell 不提取验证消息,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18845770/