开发者

Symfony: using $this->widgetSchema->setFormFormatterName('list')

im using $this->widgetSchema->setFormFormatterName('list'); this way below to render my form as a list but it is still a t开发者_开发技巧able. Any idea?

public function configure()
  {

            parent::configure();

            $this->widgetSchema->setFormFormatterName('list');

  }

}

Any idea?

Javi


to apply a formatter to all the forms use the following line in the setup() of your config\ProjectConfiguration.class.php

class ProjectConfiguration extends sfProjectConfiguration
{
  public function setup()
  {
    sfWidgetFormSchema::setDefaultFormFormatterName('list');
  }

}
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜