15 private $userOptionsLookup;
18 parent::__construct(
'EditRecovery' );
19 $this->userOptionsLookup = $userOptionsLookup;
31 parent::execute( $subPage );
36 if ( !$this->userOptionsLookup->getOption( $this->getUser(),
'editrecovery' ) ) {
37 if ( !$this->
getUser()->isNamed() ) {
39 $this->
getOutput()->showErrorPage(
'editrecovery',
'edit-recovery-special-user-unnamed' );
42 $this->
getOutput()->showErrorPage(
'editrecovery',
'edit-recovery-special-user-not-enabled' );
47 $this->
getOutput()->addModuleStyles(
'mediawiki.special.editrecovery.styles' );
48 $this->
getOutput()->addModules(
'mediawiki.special.editrecovery' );
49 $this->
getOutput()->addModuleStyles(
'mediawiki.codex.messagebox.styles' );
50 $noJs = Html::errorBox(
51 $this->
msg(
'edit-recovery-nojs-placeholder' )->parse(),
53 'mw-special-EditRecovery-nojs-notice'
55 $placeholder = Html::rawElement(
'div', [
'class' =>
'mw-special-EditRecovery-app' ], $noJs );
56 $this->
getOutput()->addHTML( $placeholder );
Parent class for all special pages.
getUser()
Shortcut to get the User executing this instance.
msg( $key,... $params)
Wrapper around wfMessage that sets the current context.
getOutput()
Get the OutputPage being used for this instance.
addHelpLink( $to, $overrideBaseUrl=false)
Adds help link with an icon via page indicators.