Jump to content

HelperForm toolbar button not shown


Koko888

Recommended Posts

Hello,

 

I'm trying to generate a sample form, but I can't get the 'save' button in the toolbar, here the code:

public function formCategories()
    {
        $fields_form = array(
            'form' => array(
                'legend' => array(
                    'title' => $this->l('some title'),
                ),
                'description' =>
                    '<ul>
                        <li>'.$this->l('some description.').'</li>
                    </ul>',  
                'submit' => array(
                    'title' => $this->l('Save'),
                ),
                'buttons' => array(
                    array(
                        'href' => 'http://someurl',
                        'title' => 'Generar',
                        'icon' => 'some-icon',
                    )
                ),                
            ),
        );
        
        $helper = new HelperForm();
        $helper->title = ;
        $helper->show_toolbar = true;
        return $helper->generateForm(array($fields_form));
    } 

This code only generates the button in the 'buttons' array  but not the 'save' button in 'submit' array. Any idea of what I'm doing wrong?

 

Thanks in advance

Edited by Koko888 (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...