/**
  * Constructor
  * 
  * @return  void
  */
 function FormBackbutton()
 {
     parent::FormButton();
     $this->setAttribute('id', 'backbutton');
     $this->setAttribute('value', 'Back');
     $this->setAttribute('onclick', "javascript:window.history.back();");
 }
Esempio n. 2
0
 function init()
 {
     parent::init();
     $this->template->trySet('type', 'submit');
     if ($this->owner->js_widget) {
         $this->js('click', array($this->owner->js()->find('input[name=ajax_submit]')->val($this->short_name), $this->owner->js()->submit()));
     }
 }
Esempio n. 3
0
 /**
  * @desc Adds a button to the form
  * @param FormButton $button The button to add
  */
 public function add_button(FormButton $button)
 {
     $button->set_form_id($this->html_id);
     $this->buttons[] = $button;
 }