<?php
/**
- * action=edit handler
- *
- * Copyright © 2012 Timo Tijhof
- *
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
*
* @file
* @ingroup Actions
- * @author Timo Tijhof
*/
/**
- * Page edition handler
+ * Page edition handler (action=edit)
*
* This is a wrapper that will call the EditPage class or a custom editor from an extension.
*
$out = $this->getOutput();
$out->setRobotPolicy( 'noindex,nofollow' );
if ( $this->getContext()->getConfig()->get( 'UseMediaWikiUIEverywhere' ) ) {
- $out->addModuleStyles( array(
+ $out->addModuleStyles( [
'mediawiki.ui.input',
'mediawiki.ui.checkbox',
- ) );
+ ] );
}
$page = $this->page;
$user = $this->getUser();
- if ( Hooks::run( 'CustomEditor', array( $page, $user ) ) ) {
+ if ( Hooks::run( 'CustomEditor', [ $page, $user ] ) ) {
$editor = new EditPage( $page );
+ $editor->setContextTitle( $this->getTitle() );
$editor->edit();
}
}