-
-
Save tournasdim/9997030 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Helloworld\Form; | |
use Zend\Form\Form; | |
class SignUp extends Form | |
{ | |
public function __construct() | |
{ | |
parent::__construct('signUp'); | |
$this->setAttribute('action', '/signup'); | |
$this->setAttribute('method', 'post'); | |
$this->add(array( | |
'name' => 'name', | |
'attributes' => array( | |
'type' => 'text', | |
'id' => 'name' | |
), | |
'options' => array( | |
'label' => 'Ihr Name:' | |
), | |
)); | |
$this->add(array( | |
'name' => 'email', | |
'attributes' => array( | |
'type' => 'email', | |
'id' => 'email' | |
), | |
'options' => array( | |
'label' => 'Ihre E-Mail-Adresse:' | |
), | |
)); | |
$this->add(array( | |
'name' => 'submit', | |
'attributes' => array( | |
'type' => 'submit', | |
'value' => 'Eintragen' | |
), | |
)); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment