/** * Class constuctor. * * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form $form) { parent::__construct($name, $form); $this->getAttributes()->setAttribute('type', 'file'); $this->getFormObject()->addEnctype(); }
/** * Constructor. * * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form &$form) { parent::__construct($name, $form); $this->getAttributes()->setAttribute('type', 'checkbox'); }
/** * Constructor. * * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form &$form) { parent::__construct($name, $form); $this->getAttributes()->addToAttribute('class', 'form-control'); }
/** * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form &$form) { parent::__construct($name, $form); $this->getAttributes()->setAttribute('type', 'text'); $this->getAttributes()->addToAttribute('class', 'form-control input-sm'); }
/** * Constructor * * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form &$form) { parent::__construct($name, $form); $mValue = $this->getValue(); if (empty($mValue)) { $this->setValue(['day' => '', 'month' => '', 'year' => '']); } }
/** * Constructor. * * @access public * @param string $name * @param Form $form * @since 1.0.0-alpha * @version 1.0.0-alpha */ public function __construct($name, Form &$form) { // add reCaptcha JavaScript API Router::getInstance()->getController()->addJs('https://www.google.com/recaptcha/api.js?hl=pl'); // get private and public keys $this->sPublickey = Config::get('recaptcha.publickey'); $this->sPrivatekey = Config::get('recaptcha.privatekey'); // parent construct parent::__construct($name, $form); }