< Manual:Hooks 
 
      | SkinAfterBottomScripts | |
|---|---|
| Available from version 1.11.0 At the end of Skin::bottomScripts() | |
| Define function: | public static function onSkinAfterBottomScripts( $skin, &$text ) { ... }
 | 
| Attach hook: | In extension.json: {
	"Hooks": {
		"SkinAfterBottomScripts": "MyExtensionHooks::onSkinAfterBottomScripts"
	}
}
 | 
| Called from: | File(s): Skin.php | 
| Interface: | SkinAfterBottomScriptsHook.php | 
For more information about attaching hooks, see Manual:Hooks.
For examples of extensions using this hook, see Category:SkinAfterBottomScripts extensions.
Details
- $skin: Skin object
- &$text: bottomScripts Text. Append to $text to add additional text/scripts after the stock bottom scripts.
Delete default buttons
$wgHooks["SkinAfterBottomScripts"][] = "AssetsClass::onSkinAfterBottomScripts";
class AssetsClass {
  public static function onSkinAfterBottomScripts( $skin, &$text ) {
    $text = preg_replace("/^mw\.loader\.using\(\"mediawiki\.action\.edit\"[^\n]+\n/m", "", $text);
    return true;
  }
}
    This article is issued from Mediawiki. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.