コード例 #1
0
ファイル: User.php プロジェクト: GSilva18/SISEDS
 public function __construct($name = null, $options = array())
 {
     parent::__construct('user', $options);
     $this->setInputFilter(new UserFilter());
     $this->setAttribute('methos', 'post');
     $id = new \Zend\Form\Element\Hidden('id');
     $this->add($id);
     $nome = new \Zend\Form\Element\Text("nome");
     $nome->setLabel("Nome")->setAttribute('placeholder', 'Entre com o nome');
     $this->add($nome);
     $email = new \Zend\Form\Element\Text("email");
     $email->setLabel("Email")->setAttribute('placeholder', 'Entre com o email');
     $this->add($email);
     $cpf = new \Zend\Form\Element\Text("cpf");
     $cpf->setLabel("CPF")->setAttribute('placeholder', 'Entre com o CPF');
     $this->add($cpf);
     $passsword = new \Zend\Form\Element\Password("password");
     $passsword->setLabel("Senha")->setAttribute('placeholder', 'Entre com a Senha');
     $this->add($passsword);
     $confirmation = new \Zend\Form\Element\Password("confirmation");
     $confirmation->setLabel("Redigite: ")->setAttribute('placeholder', 'Redigite a Senha');
     $this->add($confirmation);
     $csrf = new \Zend\Form\Element\Csrf("security");
     $this->add($csrf);
     $this->add(array('name' => 'submit', 'type' => 'Zend\\Form\\Element\\Submit', 'attributes' => array('value' => 'Salvar', 'class' => 'btn-success')));
 }
コード例 #2
0
ファイル: Login.php プロジェクト: Tortinhex/son-zf2-inter
 /**
  * @param null $name
  * @param array $options
  */
 public function __construct($name = null, $options = array())
 {
     parent::__construct('user', $options);
     $this->setAttribute('method', 'post');
     $email = new \Zend\Form\Element\Email('email');
     $email->setLabel('Email: ')->setAttribute('placeholder', 'Entre com o email');
     $this->add($email);
     $password = new \Zend\Form\Element\Password('password');
     $password->setLabel('Senha: ')->setAttribute('placeholder', 'Entre com a senha');
     $this->add($password);
     $this->add(array('name' => 'submit', 'type' => 'Zend\\Form\\Element\\Submit', 'attributes' => array('value' => 'Entrar', 'class' => 'btn-success')));
 }
コード例 #3
0
ファイル: Login.php プロジェクト: souzagabi/Agenda
 public function __construct($name = null, $options = array())
 {
     parent::__construct('Login', $options);
     $this->setAttribute('method', 'post');
     $email = new \Zend\Form\Element\Text("email");
     $email->setLabel("Email: ")->setAttribute('placeholder', 'Entre com o Email')->setAttribute('autofocus', 'autofocus');
     $this->add($email);
     $password = new \Zend\Form\Element\Password("password");
     $password->setLabel("Password: ")->setAttribute('placeholder', 'Entre com a senha');
     $this->add($password);
     $this->add(array('name' => 'submit', 'type' => 'Zend\\Form\\Element\\Submit', 'attributes' => array('value' => 'Autenticar', 'class' => 'btn btn-success')));
 }
コード例 #4
0
ファイル: Login.php プロジェクト: phtfao/geframa
 public function __construct($name = null, $options = array())
 {
     parent::__construct($name, $options);
     $this->setAttribute('method', 'post');
     $email = new \Zend\Form\Element\Text("email");
     $email->setLabel("Email: ")->setAttribute('placeholder', 'Email')->setAttribute('class', 'form-control');
     $this->add($email);
     $password = new \Zend\Form\Element\Password("password");
     $password->setLabel("Password: "******"submit");
     $submit->setAttribute('value', 'Entrar')->setAttribute('class', 'btn btn-primary btn-block btn-flat');
     $this->add($submit);
 }
コード例 #5
0
ファイル: Login.php プロジェクト: hschletz/braintacle
 /** {@inheritdoc} */
 public function init()
 {
     parent::init();
     $user = new \Zend\Form\Element\Text('User');
     $user->setLabel('Username');
     $this->add($user);
     $password = new \Zend\Form\Element\Password('Password');
     $password->setLabel('Password');
     $this->add($password);
     $submit = new \Library\Form\Element\Submit('Submit');
     $submit->setLabel('Login');
     $this->add($submit);
     $inputFilter = $this->getInputFilter();
     $inputFilter->get('User')->setAllowEmpty(true);
     $inputFilter->get('Password')->setAllowEmpty(true);
 }
コード例 #6
0
ファイル: User.php プロジェクト: alexcomput/ZF2Projects
 public function __construct($name = null, $options = array())
 {
     parent::__construct('user', $options);
     $this->setInputFilter(new UserFilter());
     $this->setAttribute('methos', 'post');
     $id = new \Zend\Form\Element\Hidden('id');
     $this->add($id);
     $nome = new \Zend\Form\Element\Text('nome');
     $nome->setLabel('Nome:')->setAttribute('placeholder', 'Entre com o Nome');
     $this->add($nome);
     $email = new \Zend\Form\Element\Text('email');
     $email->setLabel('Email:')->setAttribute('placeholder', 'Entre com o Email');
     $this->add($email);
     $password = new \Zend\Form\Element\Password('password');
     $password->setLabel('Password:'******'placeholder', 'Entre com o Password');
     $this->add($password);
     $confirmation = new \Zend\Form\Element\Password('confirmation ');
     $confirmation->setLabel('Password:'******'placeholder', 'Regidite a Senha ');
     $this->add($confirmation);
     $csrf = new \Zend\Form\Element\Csrf('security');
     $this->add($csrf);
     $this->add(array('name' => 'Submit', 'type' => '\\Zend\\Form\\Element\\Submit', 'attributes' => array('value' => 'Salvar', 'class' => 'btn-sucess')));
 }