2011-11-28 20:28:28 +00:00
|
|
|
<?php
|
|
|
|
/**
|
|
|
|
* Sandbox SpecialPage for VisualEditor extension
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @ingroup Extensions
|
|
|
|
*/
|
|
|
|
|
|
|
|
class SpecialVisualEditorSandbox extends SpecialPage {
|
|
|
|
|
|
|
|
/* Methods */
|
|
|
|
|
|
|
|
public function __construct() {
|
|
|
|
parent::__construct( 'VisualEditorSandbox' );
|
|
|
|
}
|
|
|
|
|
|
|
|
public function execute( $par ) {
|
|
|
|
global $wgOut;
|
|
|
|
|
2011-12-13 02:46:31 +00:00
|
|
|
$wgOut->addModules( 'ext.visualEditor.special.sandbox' );
|
2011-11-28 20:28:28 +00:00
|
|
|
$this->setHeaders();
|
|
|
|
$wgOut->setPageTitle( wfMsg( 'visualeditor-sandbox-title' ) );
|
2011-12-11 23:28:29 +00:00
|
|
|
$modeWikitext = wfMsgHtml( 'visualeditor-tooltip-wikitext' );
|
|
|
|
$modeJson = wfMsgHtml( 'visualeditor-tooltip-json' );
|
|
|
|
$modeHtml = wfMsgHtml( 'visualeditor-tooltip-html' );
|
|
|
|
$modeRender = wfMsgHtml( 'visualeditor-tooltip-render' );
|
|
|
|
$modeHistory = wfMsgHtml( 'visualeditor-tooltip-history' );
|
2011-12-12 22:09:15 +00:00
|
|
|
$modeHelp = wfMsgHtml( 'visualeditor-tooltip-help' );
|
2011-12-13 02:46:31 +00:00
|
|
|
|
2011-12-13 04:06:02 +00:00
|
|
|
$dir = dirname( __FILE__ );
|
|
|
|
ob_start();
|
|
|
|
include( 'modules/sandbox/base.php' );
|
|
|
|
$out = ob_get_clean();
|
2011-11-28 20:28:28 +00:00
|
|
|
$wgOut->addHtml( $out );
|
|
|
|
}
|
|
|
|
}
|