original_string: private function print_version_view() {
          global $CFG, $OUTPUT, $PAGE;
          $pageversion = wiki_get_version($this->version->id);
  
          if ($pageversion) {
              $restorelink = new moodle_url('/mod/wiki/restoreversion.php', array('pageid' => $this->page->id, 'versionid' => $this->version->id));
              echo html_writer::tag('div', get_string('viewversion', 'wiki', $pageversion->version) . '<br />' .
                  html_writer::link($restorelink->out(false), '(' . get_string('restorethis', 'wiki') .
                  ')', array('class' => 'wiki_restore')) . '&nbsp;', array('class' => 'wiki_headingtitle'));
              $userinfo = wiki_get_user_info($pageversion->userid);
              $heading = '<p><strong>' . get_string('modified', 'wiki') . ':</strong>&nbsp;' . userdate($pageversion->timecreated, get_string('strftimedatetime', 'langconfig'));
              $viewlink = new moodle_url('/user/view.php', array('id' => $userinfo->id));
              $heading .= '&nbsp;&nbsp;&nbsp;<strong>' . get_string('user') . ':</strong>&nbsp;' . html_writer::link($viewlink->out(false), fullname($userinfo));
              $heading .= '&nbsp;&nbsp;&rarr;&nbsp;' . $OUTPUT->user_picture(wiki_get_user_info($pageversion->userid), array('popup' => true)) . '</p>';
              echo $OUTPUT->container($heading, 'wiki_headingtime', 'wiki_modifieduser');
              $options = array('swid' => $this->subwiki->id, 'pretty_print' => true, 'pageid' => $this->page->id);
  
              $pageversion->content = file_rewrite_pluginfile_urls($pageversion->content, 'pluginfile.php', $this->modcontext->id, 'mod_wiki', 'attachments', $this->subwiki->id);
  
              $parseroutput = wiki_parse_content($pageversion->contentformat, $pageversion->content, $options);
              $content = $OUTPUT->container(format_text($parseroutput['parsed_text'], FORMAT_HTML, array('overflowdiv'=>true)), false, '', '', true);
              echo $OUTPUT->box($content, 'generalbox wiki_contentbox');
  
          } else {
              print_error('versionerror', 'wiki');
          }
      }
code: private function print_version_view() {
          global $CFG, $OUTPUT, $PAGE;
          $pageversion = wiki_get_version($this->version->id);
  
          if ($pageversion) {
              $restorelink = new moodle_url('/mod/wiki/restoreversion.php', array('pageid' => $this->page->id, 'versionid' => $this->version->id));
              echo html_writer::tag('div', get_string('viewversion', 'wiki', $pageversion->version) . '<br />' .
                  html_writer::link($restorelink->out(false), '(' . get_string('restorethis', 'wiki') .
                  ')', array('class' => 'wiki_restore')) . '&nbsp;', array('class' => 'wiki_headingtitle'));
              $userinfo = wiki_get_user_info($pageversion->userid);
              $heading = '<p><strong>' . get_string('modified', 'wiki') . ':</strong>&nbsp;' . userdate($pageversion->timecreated, get_string('strftimedatetime', 'langconfig'));
              $viewlink = new moodle_url('/user/view.php', array('id' => $userinfo->id));
              $heading .= '&nbsp;&nbsp;&nbsp;<strong>' . get_string('user') . ':</strong>&nbsp;' . html_writer::link($viewlink->out(false), fullname($userinfo));
              $heading .= '&nbsp;&nbsp;&rarr;&nbsp;' . $OUTPUT->user_picture(wiki_get_user_info($pageversion->userid), array('popup' => true)) . '</p>';
              echo $OUTPUT->container($heading, 'wiki_headingtime', 'wiki_modifieduser');
              $options = array('swid' => $this->subwiki->id, 'pretty_print' => true, 'pageid' => $this->page->id);
  
              $pageversion->content = file_rewrite_pluginfile_urls($pageversion->content, 'pluginfile.php', $this->modcontext->id, 'mod_wiki', 'attachments', $this->subwiki->id);
  
              $parseroutput = wiki_parse_content($pageversion->contentformat, $pageversion->content, $options);
              $content = $OUTPUT->container(format_text($parseroutput['parsed_text'], FORMAT_HTML, array('overflowdiv'=>true)), false, '', '', true);
              echo $OUTPUT->box($content, 'generalbox wiki_contentbox');
  
          } else {
              print_error('versionerror', 'wiki');
          }
      }
code_tokens: private function print_version_view ( ) { global $ CFG , $ OUTPUT , $ PAGE ; $ pageversion = wiki_get_version ( $ this -> version -> id ) ; if ( $ pageversion ) { $ restorelink = new moodle_url ( '/mod/wiki/restoreversion.php' , array ( 'pageid' => $ this -> page -> id , 'versionid' => $ this -> version -> id ) ) ; echo html_writer :: tag ( 'div' , get_string ( 'viewversion' , 'wiki' , $ pageversion -> version ) . '<br />' . html_writer :: link ( $ restorelink -> out ( false ) , '(' . get_string ( 'restorethis' , 'wiki' ) . ')' , array ( 'class' => 'wiki_restore' ) ) . '&nbsp;' , array ( 'class' => 'wiki_headingtitle' ) ) ; $ userinfo = wiki_get_user_info ( $ pageversion -> userid ) ; $ heading = '<p><strong>' . get_string ( 'modified' , 'wiki' ) . ':</strong>&nbsp;' . userdate ( $ pageversion -> timecreated , get_string ( 'strftimedatetime' , 'langconfig' ) ) ; $ viewlink = new moodle_url ( '/user/view.php' , array ( 'id' => $ userinfo -> id ) ) ; $ heading .= '&nbsp;&nbsp;&nbsp;<strong>' . get_string ( 'user' ) . ':</strong>&nbsp;' . html_writer :: link ( $ viewlink -> out ( false ) , fullname ( $ userinfo ) ) ; $ heading .= '&nbsp;&nbsp;&rarr;&nbsp;' . $ OUTPUT -> user_picture ( wiki_get_user_info ( $ pageversion -> userid ) , array ( 'popup' => true ) ) . '</p>' ; echo $ OUTPUT -> container ( $ heading , 'wiki_headingtime' , 'wiki_modifieduser' ) ; $ options = array ( 'swid' => $ this -> subwiki -> id , 'pretty_print' => true , 'pageid' => $ this -> page -> id ) ; $ pageversion -> content = file_rewrite_pluginfile_urls ( $ pageversion -> content , 'pluginfile.php' , $ this -> modcontext -> id , 'mod_wiki' , 'attachments' , $ this -> subwiki -> id ) ; $ parseroutput = wiki_parse_content ( $ pageversion -> contentformat , $ pageversion -> content , $ options ) ; $ content = $ OUTPUT -> container ( format_text ( $ parseroutput [ 'parsed_text' ] , FORMAT_HTML , array ( 'overflowdiv' => true ) ) , false , '' , '' , true ) ; echo $ OUTPUT -> box ( $ content , 'generalbox wiki_contentbox' ) ; } else { print_error ( 'versionerror' , 'wiki' ) ; } }
docstring: Given an old page version, output the version content
  
  @global object $CFG
  @global object $OUTPUT
  @global object $PAGE
docstring_tokens: Given an old page version output the version content