General

Skip to end of metadata
Go to start of metadata
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.
  1. Apr 20, 2011

    jason fonseca says:

    How do I create a form in Pimcore? I don't understand, I tried extending Zend_F...

    How do I create a form in Pimcore? I don't understand,

    I tried extending Zend_Form creating a form like this (see below).

    Called the file Application_Form_Login.php and saved it in my models/forms/ directory "
    under website. 

    When I attempted to create a new object of type Application_Form_Login, an error told me
    that the file couldn't be found. What am I doing wrong? Is this the correct way to make a form?

    class Application_Form_Login extends Zend_Form{   
    public function init()    {        
    $this->setName("login");       
     $this->setMethod('post');                 
        $this->addElement('text', 'username', array(      
          'filters'    => array('StringTrim', 'StringToLower'),   
             'validators' => array(               
     array('StringLength', false, array(0, 50)),  
              ),            'required'   => true,      
          'label'      => 'Username:',        ));