/**
  * Sets value from comma separated values or array.
  * @param mixed $value
  */
 public function setValue($value)
 {
     if (!is_array($value)) {
         $values = array_map('trim', explode(',', $value));
     } else {
         $values = $value;
     }
     parent::setValue($values);
 }
示例#2
0
 public function init()
 {
     parent::init();
     $this->addPrefixPath('Application_Form_Decorator', 'Application/Form/Decorator', Zend_Form::DECORATOR);
     $this->setMultiOptions($this->getRolesMultiOptions());
 }