MediaWiki:Gadget-renameuser.js

/* Adds a link on User pages to Special:RenameUser */ jQuery( document ).ready( function {  if (mw.config.get( 'wgTitle').indexOf("/") !== -1 || document.title.indexOf("- History -") !== -1)  //no subpages or history     return;  if (mw.config.get( 'wgCanonicalNamespace') === "User" || mw.config.get( 'wgCanonicalNamespace') == "User_talk") {     var username = mw.config.get( 'wgTitle' );     mw.util.addPortletLink("p-cactions", mw.util.getUrl( "Special:RenameUser/" + username ), "Rename user", "ca-contrib", "Rename this user");  } } );