MediaWiki REL1_37
WebInstallerDocument.php
Go to the documentation of this file.
1<?php
22abstract class WebInstallerDocument extends WebInstallerPage {
23
27 abstract protected function getFileName();
28
29 public function execute() {
30 $text = $this->getFileContents();
31 $text = InstallDocFormatter::format( $text );
32 $this->parent->output->addWikiTextAsInterface( $text );
33 $this->startForm();
34 $this->endForm( false );
35 return '';
36 }
37
41 public function getFileContents() {
42 $file = __DIR__ . '/../../' . $this->getFileName();
43 if ( !file_exists( $file ) ) {
44 return wfMessage( 'config-nofile', $file )->plain();
45 }
46
47 return file_get_contents( $file );
48 }
49
50}
wfMessage( $key,... $params)
This is the function for getting translated interface messages.
Abstract class to define pages for the web installer.
endForm( $continue='continue', $back='back')
if(PHP_SAPI !='cli-server') if(!isset( $_SERVER['SCRIPT_FILENAME'])) $file
Item class for a filearchive table row.
Definition router.php:42