Created
May 23, 2011 19:31
-
-
Save eminetto/987374 to your computer and use it in GitHub Desktop.
ProfessorForm
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 | |
class ProfessorForm extends PessoaForm { | |
public function __construct($options = null) { | |
parent::__construct($options); | |
$this->generate(); | |
} | |
private function generate() { | |
$disciplina = new Zend_Form_Element_Text('disciplina'); | |
$disciplina->setLabel('Disciplina')->setRequired(true)->addFilter('StripTags')->addValidator('NotEmpty'); | |
$submit = new Zend_Form_Element_Submit('submit'); | |
$submit->setLabel('Entrar'); | |
$submit->setAttrib('id', 'Entrar'); | |
$this->addElements(array($disciplina,$submit)); | |
//action e method | |
$this->setAction(BASE_URL.'/professor/index')->setMethod('post'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment