/** * Render the special page * @param string|null $par Parameter submitted as subpage */ public function execute($par = '') { parent::execute($par); $context = MobileContext::singleton(); wfIncrStats('mobile.options.views'); $this->returnToTitle = Title::newFromText($this->getRequest()->getText('returnto')); if (!$this->returnToTitle) { $this->returnToTitle = Title::newMainPage(); } $this->setHeaders(); $context->setForceMobileView(true); $context->setContentTransformations(false); if (isset($this->options[$par])) { $option = $this->options[$par]; if ($this->getRequest()->wasPosted() && isset($option['post'])) { $func = $option['post']; } else { $func = $option['get']; } $this->{$func}(); } else { if ($this->getRequest()->wasPosted()) { $this->submitSettingsForm(); } else { $this->getSettingsForm(); } } }
/** * Render the special page * @param string|null $par Parameter submitted as subpage */ public function execute($par = '') { parent::execute($par); $context = MobileContext::singleton(); wfIncrStats('mobile.options.views'); $this->returnToTitle = Title::newFromText($this->getRequest()->getText('returnto')); if (!$this->returnToTitle) { $this->returnToTitle = Title::newMainPage(); } $this->setHeaders(); $context->setForceMobileView(true); $context->setContentTransformations(false); // check, if the subpage has a registered function, that needs to be executed if (isset($this->options[$par])) { $option = $this->options[$par]; // select the correct function for the given request method (post, get) if ($this->getRequest()->wasPosted() && isset($option['post'])) { $func = $option['post']; } else { $func = $option['get']; } // run the function $this->{$func}(); } else { if ($this->getRequest()->wasPosted()) { $this->submitSettingsForm(); } else { $this->getSettingsForm(); } } }
/** * Render the special page content * @param string $par parameters submitted as subpage */ public function execute($par) { $out = $this->getOutput(); $out->addModuleStyles('mobile.special.pagefeed.styles'); $this->setHeaders(); $out->setProperty('unstyledContent', true); parent::execute($par); }
/** * Construct function */ public function __construct() { parent::__construct('MobileMenu'); $supported = array('vector', 'minerva'); $name = $this->getSkin()->getSkinName(); if (array_search($name, $supported) !== false) { $this->hasDesktopVersion = true; } }
/** * Construct function */ public function __construct() { parent::__construct('Uploads'); }
/** * Construct function */ public function __construct() { parent::__construct('Nearby'); $this->listed = true; }
public function __construct() { // Un-list this page on Special:SpecialPages parent::__construct('TopicTag', '', false); $this->tagName = ''; }
/** * Construct function */ public function __construct() { parent::__construct('UserProfile'); }
/** * Construct function */ public function __construct() { parent::__construct('MobileEditor'); $this->listed = false; }
/** * Construct function */ public function __construct() { parent::__construct('MobileDiff'); }
/** * Construct function */ public function __construct() { parent::__construct('MobileLanguages'); }