开发者

set two different labels for two different pages that use the same form - symfony

I have a form and I need to set labels for two different kind of pages. I tried to used $this->widgetSchema->setLabels... with an if and with $sf_params->get('module') and $sf_params->get('action') but I got an error saying that $sf_params is an undefined variable. What can I do to solve this开发者_JS百科?


In your template, you can pass to renderLabel() the label you want.

$form['xxx']->renderLabel('Your label')
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜