MediaWiki coding conventions is to use the WebRequest object.
In the context of a SpecialPage subclass, you would probably do $this->getRequest()->getVal( 'reason' ); [Note: This combines both POST and GET values]
See https://doc.wikimedia.org/mediawiki-core/master/php/classWebRequest.html#a3e... for more details.
-- Brian
On Tue, Oct 1, 2019 at 7:51 PM John Shepherd MajorJohn1@mail.com wrote:
Is there a “special” way in mediawiki to get parameters passed by URL or do you just use the conventional PHP way ($_GET)? I am trying to check if “Special:CreateAccount?reason=“ is set/has a value (and what that value is).
Thank you for your assistance, trying to be convention compliant. -TheSandDoctor
Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l