original_string: public function display(core_backup_renderer $renderer) {
          $form = $this->initialise_stage_form();
          $form->require_definition_after_data();
          if ($e = $form->get_element('submitbutton')) {
              $e->setLabel(get_string('import'.$this->get_ui()->get_name().'stage'.$this->get_stage().'action', 'backup'));
          } else {
              $elements = $form->get_element('buttonar')->getElements();
              foreach ($elements as &$element) {
                  if ($element->getName() == 'submitbutton') {
                      $element->setValue(
                          get_string('import'.$this->get_ui()->get_name().'stage'.$this->get_stage().'action', 'backup')
                      );
                  }
              }
          }
  
          // A nasty hack follows to work around the sad fact that moodle quickforms
          // do not allow to actually return the HTML content, just to echo it.
          flush();
          ob_start();
          $form->display();
          $output = ob_get_contents();
          ob_end_clean();
  
          return $output;
      }
code: public function display(core_backup_renderer $renderer) {
          $form = $this->initialise_stage_form();
          $form->require_definition_after_data();
          if ($e = $form->get_element('submitbutton')) {
              $e->setLabel(get_string('import'.$this->get_ui()->get_name().'stage'.$this->get_stage().'action', 'backup'));
          } else {
              $elements = $form->get_element('buttonar')->getElements();
              foreach ($elements as &$element) {
                  if ($element->getName() == 'submitbutton') {
                      $element->setValue(
                          get_string('import'.$this->get_ui()->get_name().'stage'.$this->get_stage().'action', 'backup')
                      );
                  }
              }
          }
  
          // A nasty hack follows to work around the sad fact that moodle quickforms
          // do not allow to actually return the HTML content, just to echo it.
          flush();
          ob_start();
          $form->display();
          $output = ob_get_contents();
          ob_end_clean();
  
          return $output;
      }
code_tokens: public function display ( core_backup_renderer $ renderer ) { $ form = $ this -> initialise_stage_form ( ) ; $ form -> require_definition_after_data ( ) ; if ( $ e = $ form -> get_element ( 'submitbutton' ) ) { $ e -> setLabel ( get_string ( 'import' . $ this -> get_ui ( ) -> get_name ( ) . 'stage' . $ this -> get_stage ( ) . 'action' , 'backup' ) ) ; } else { $ elements = $ form -> get_element ( 'buttonar' ) -> getElements ( ) ; foreach ( $ elements as & $ element ) { if ( $ element -> getName ( ) == 'submitbutton' ) { $ element -> setValue ( get_string ( 'import' . $ this -> get_ui ( ) -> get_name ( ) . 'stage' . $ this -> get_stage ( ) . 'action' , 'backup' ) ) ; } } } // A nasty hack follows to work around the sad fact that moodle quickforms // do not allow to actually return the HTML content, just to echo it. flush ( ) ; ob_start ( ) ; $ form -> display ( ) ; $ output = ob_get_contents ( ) ; ob_end_clean ( ) ; return $ output ; }
docstring: Displays the stage
  
  This function is overriden so that we can manipulate the strings on the
  buttons.
  
  @param core_backup_renderer $renderer
  @return string HTML code to echo
docstring_tokens: Displays the stage