32 parent::__construct(
'ApiHelp' );
33 $this->urlUtils = $urlUtils;
38 $this->
getOutput()->addModuleStyles(
'mediawiki.codex.messagebox.styles' );
48 'submodules' => $request->getCheck(
'submodules' ),
49 'recursivesubmodules' => $request->getCheck(
'recursivesubmodules' ),
50 'title' => $request->getVal(
'title', $this->
getPageTitle(
'$1' )->getPrefixedText() ),
56 if ( str_starts_with( $par,
'sub/' ) ) {
57 $par = substr( $par, 4 );
58 $options[
'submodules'] = 1;
62 if ( str_starts_with( $par,
'rsub/' ) ) {
63 $par = substr( $par, 5 );
64 $options[
'recursivesubmodules'] = 1;
71 if ( !isset( $moduleName ) ) {
72 throw new LogicException(
'Module name should have been found' );
76 unset( $options[
'nolead'], $options[
'title'] );
77 $options[
'modules'] = $moduleName;
85 $module = $main->getModuleFromPath( $moduleName );
87 $this->
getOutput()->addHTML( Html::errorBox(
88 $this->
msg(
'apihelp-no-such-module', $moduleName )->inContentLanguage()->parse()
103class_alias( SpecialApiHelp::class,
'SpecialApiHelp' );
wfAppendQuery( $url, $query)
Append a query string to an existing URL, which may or may not already have query string parameters a...
wfScript( $script='index')
Get the URL path to a MediaWiki entry point.
This is the main API class, used for both external and internal processing.
getPageTitle( $subpage=false)
Get a self-referential title object.
getContext()
Gets the context this SpecialPage is executed in.
getRequest()
Get the WebRequest being used for this instance.
msg( $key,... $params)
Wrapper around wfMessage that sets the current context.
getOutput()
Get the OutputPage being used for this instance.
including( $x=null)
Whether the special page is being evaluated via transclusion.
Shortcut to construct a special page which is unlisted by default.