Ejemplo n.º 1
0
 public function __construct($name, $options = array(), $attributes = null)
 {
     parent::__construct($name, $attributes);
     $this->_inner_form = new \Phalcon\Forms\Form();
     $this->_field_options = (array) $options;
     foreach ($this->_field_options as $check_key => $check_val) {
         $field_options = array('name' => $name . '[]', 'value' => $check_key);
         $element = new \Phalcon\Forms\Element\Check($name . '_' . $check_key, $field_options);
         $element->setLabel($check_val);
         $this->_inner_form->add($element);
     }
 }
Ejemplo n.º 2
0
 private function _Isadmin()
 {
     $element = new \Phalcon\Forms\Element\Check("Isadmin");
     $element->setLabel("Isadmin");
     return $element;
 }