public function __construct($spec = '', $options = '') { parent::__construct($spec, $options); // $table = new AttributeDescriptor(); // $select = $table->select(); // $select->order(AttributeDescriptor::COL_NAME); // $select->where(AttributeDescriptor::COL_SHOW_IN_LIST . "= ?", 1); // if ($group != '') { // $select->where(AttributeDescriptor::COL_GROUP . "= ?",$group); // } // $rowset = $table->fetchAll($select); // $array = $rowset->toArray(); // $optArray = array(null=>'Please select'); // // foreach ($array as $value) { // $optArray = $optArray + array($value[AttributeDescriptor::COL_ID]=>$value[AttributeDescriptor::COL_NAME]); // } // $this->setMultiOptions($optArray); $from = new Zend_Form_Element_Text($spec); $this->setIsArray(TRUE); $to = new Zend_Form_Element_Text($spec); $this->setIsArray(TRUE); $this->add($from); $this->add($to); //$this-> }
public function __construct($script, $spec, $wide = true, $options = null, $class = null) { parent::__construct($spec, $options); if ($wide == true) { $this->setDecorators(array('ViewScript', array(array('element' => 'HtmlTag'), array('tag' => 'td', 'colspan' => 2)), array(array('elementTr' => 'HtmlTag'), array('tag' => 'tr', 'class' => 'snep_form_element ' . $class)))); } else { $this->setDecorators(array('ViewScript', array(array('element' => 'HtmlTag'), array('tag' => 'td')), array('Label', array('tag' => 'th')), array(array('elementTr' => 'HtmlTag'), array('tag' => 'tr', 'class' => 'snep_form_element ' . $class)))); } $this->getDecorator('ViewScript')->setViewScript($script); }
public function __construct($spec, $options = null) { if (empty($options['id'])) { $options['id'] = ''; } $options['ignore'] = true; parent::__construct($spec, $options); $this->clearDecorators(); $this->setDecorators(array('ViewHelper')); }
/** * Constructor for element and adds validator * * @param array|string|Zend_Config $spec * @param null $options * @throws \Zend_Exception * @throws \Zend_Form_Exception */ public function __construct($spec, $options = null) { if (empty($options['siteKey']) || empty($options['secretKey'])) { throw new \Zend_Exception('Site key and secret key must be specified.'); } $this->_siteKey = trim($options['siteKey']); // trim the white space if there is any just to be sure $this->_secretKey = trim($options['secretKey']); // trim the white space if there is any just to be sure $this->addValidator('Recaptcha', false, array('secretKey' => $this->_secretKey)); $this->setAllowEmpty(false); parent::__construct($spec, $options); }
/** * Constructor * * @param mixed $spec * @param mixed $options * @return void */ public function __construct($spec, $options = null) { $this->addPrefixPath('ZendX_JQuery_Form_Decorator', 'ZendX/JQuery/Form/Decorator', 'decorator'); parent::__construct($spec, $options); }
/** * Constructor * * @todo Should we set dojo view helper paths here? * @param mixed $spec * @param mixed $options * @return void */ public function __construct($spec, $options = null) { $this->addPrefixPath('Zend_Dojo_Form_Decorator', 'Zend/Dojo/Form/Decorator', 'decorator'); parent::__construct($spec, $options); }
public function __construct($spec, $options = null) { parent::__construct($spec, $options); $this->getView()->addHelperPath(__DIR__ . '/../Helper', 'Html5Input_Helper_'); }
/** * constructs email element * * @param string $spec * @param string $options * @author aur1mas <*****@*****.**> */ public function __construct($spec, $options = null) { parent::__construct($spec, $options); $this->addValidator(new Zend_Validate_EmailAddress()); }
public function __construct($spec, $options = null) { parent::__construct($spec, $options); $this->bsUtils = new Zendstrap_Form_MyBootstrapUtils(); }
public function __construct($spec, $options = null) { parent::__construct($spec, $options); }
public function __construct($spec, $options = null) { parent::__construct($spec, $options); $this->removeDecorator('label'); $this->removeDecorator('htmlTag'); }
/** * Elemento utilizado apenas para limpar as definições css existentas antes de sua inclusão dentro de um form * @author Jhonatan Morais <*****@*****.**> */ public function __construct() { parent::__construct($spec = 'clear'); }
public function __construct($spec, $options = null) { parent::__construct($spec, $options); $this->setDecorators(array()); }