MediaWiki REL1_39
MediaWiki\Linker\Hook\HtmlPageLinkRendererBeginHook Interface Reference

This is a hook handler interface, see docs/Hooks.md. More...

Inheritance diagram for MediaWiki\Linker\Hook\HtmlPageLinkRendererBeginHook:

Public Member Functions

 onHtmlPageLinkRendererBegin ( $linkRenderer, $target, &$text, &$customAttribs, &$query, &$ret)
 This hook is called when generating internal and interwiki links in LinkRenderer, before processing starts.
 

Detailed Description

This is a hook handler interface, see docs/Hooks.md.

Use the hook name "HtmlPageLinkRendererBegin" to register handlers implementing this interface.

Stability: stable
to implement

Definition at line 16 of file HtmlPageLinkRendererBeginHook.php.

Member Function Documentation

◆ onHtmlPageLinkRendererBegin()

MediaWiki\Linker\Hook\HtmlPageLinkRendererBeginHook::onHtmlPageLinkRendererBegin ( $linkRenderer,
$target,
& $text,
& $customAttribs,
& $query,
& $ret )

This hook is called when generating internal and interwiki links in LinkRenderer, before processing starts.

Since
1.35
Parameters
LinkRenderer$linkRenderer
LinkTarget$targetLinkTarget that the link is pointing to
string | HtmlArmor | null&$textContents that the <a> tag should have; either a plain, unescaped string or an HtmlArmor object; null means "default"
string[]&$customAttribsHTML attributes that the <a> tag should have, in associative array form, with keys and values unescaped. Should be merged with default values, with a value of false meaning to suppress the attribute.
string[]&$queryQuery string to add to the generated URL (the bit after the "?"), in associative array form, with keys and values unescaped.
string&$retValue to return if your hook returns false
Returns
bool|void True or no return value to continue, or false to skip default processing and return $ret

Implemented in MediaWiki\HookContainer\HookRunner.


The documentation for this interface was generated from the following file: