public function initialize() { $email = new \Phalcon\Forms\Element\Email('email', array('placeholder' => '*****@*****.**')); $email->setLabel('Enter Your E-Mail:'); $email->addValidator(new \Phalcon\Validation\Validator\Email(array('message' => 'The E-Mail is not valid.'))); $this->add($email); $password = new \Phalcon\Forms\Element\Password('password', array('placeholder' => 'Your password')); $password->setLabel('Password:'******'message' => 'The Password is required.'))); $this->add($password); }
public function initialize() { $email = new \Phalcon\Forms\Element\Email('email', array('placeholder' => '*****@*****.**')); $email->setLabel('Enter Your E-Mail:'); $email->addValidators(array(new \Phalcon\Validation\Validator\Email(array('message' => 'E-Mail is not valid.')))); $this->add($email); $password = new \Phalcon\Forms\Element\Password('password', array('placeholder' => 'Your password')); $password->setLabel('Password:'******'min' => 6, 'messageMinimum' => 'Password is not valid.')))); $this->add($password); $confirm_password = new \Phalcon\Forms\Element\Password('confirm_password', array('placeholder' => 'Confirm')); $confirm_password->setLabel('Confirm password:'******'with' => 'password', 'message' => 'Password doesn\'t match confirmation.'))); $this->add($confirm_password); $name = new \Phalcon\Forms\Element\Text('name', array('placeholder' => 'Ivan')); $name->setLabel('Name:'); $name->addValidators(array(new \Phalcon\Validation\Validator\StringLength(array('min' => 3, 'messageMinimum' => 'Name is not valid.')))); $this->add($name); $lastname = new \Phalcon\Forms\Element\Text('lastname', array('placeholder' => 'Ivanovich')); $lastname->setLabel('Lastname:'); $lastname->addValidators(array(new \Phalcon\Validation\Validator\StringLength(array('min' => 3, 'messageMinimum' => 'Lastname is not valid.')))); $this->add($lastname); }
private function _Password() { $element = new \Phalcon\Forms\Element\Password("Password"); $element->setLabel("Password"); return $element; }