yii2-cookbook
yii2-cookbook copied to clipboard
[qa] about global functions
trafficstars
as you said:
function t($message, $params = [], $category = 'app', $language = null)
{
return Yii::t($category, $message, $params, $language);
}
this is shorthand function for Yii::t.
My question is that how to make yii/message to meet this function.
I tried and found that, the yii/message will extract the message as Yii::t defined params order, so If i changed the order of params and the yii/message can not work well.
Any suggestion?
Yes, I think it's something it could not handle now. Needs to be improved...
Yii framework can handle this scenario will be nice.
Absolutely.