1 2 3 4 5 6 7 8 9 10 11 12
|
$this->setWidgets(array(
'titrecontenu' => new sfWidgetFormFilterInput(array('with_empty' => false)),
'textcontenu' => new sfWidgetFormFilterInput(array('with_empty' => false)),
'typecontenu' => new sfWidgetFormChoice(array('choices' => array(0=>'Tous',1=>'Page', 2=>'News')))
));
$this->setValidators(array(
'titrecontenu' => new sfValidatorPass(array('required' => false)),
'textcontenu' => new sfValidatorPass(array('required' => false)),
'typecontenu' => new sfValidatorChoice((array('required' => false, 'choices' => array(0,1,2))))
)); |
Partager