User:The Hamster/monobook.js

/*This is a monobook.js testing area for a future projects by Shadowphoenix Do not copy any of this into you monobook.js or your monobook.css

// adds a 'block logs for this user' link to the toolbox bar // if the page is not in the User namespace, then no link is displayed; the link may display in the mainspace, but should not work // should on be used on a person's userpage

addOnloadHook(function {    if ( wgCanonicalNamespace == "Special" || wgCanonicalNamespace == "Guild Wars Wiki" || wgCanonicalNamespace == "ArenaNet" || wgCanonicalNamespace == "Help" || wgCanonicalNamespace == "User talk" || wgCanonicalNamespace == "Talk" || wgCanonicalNamespace == "Guild Wars Wiki talk" || wgCanonicalNamespace == "Help talk" || wgCanonicalNamespace == "ArenaNet talk" )        return;  // don't display link for certain pages

url = wgServer + "/index.php?title=Special%3ALog&type=block&user=&page=" + wgPageName;

addPortletLink("p-tb", url, "Block logs for this user", "pt-logs"); });

//

addOnloadHook(function { if (wgTitle.indexOf("/") != -1 || document.title.indexOf("- History -") != -1)  //no subpages or history     return;  if (wgCanonicalNamespace == "User" || wgCanonicalNamespace == "User_talk") {     var username = encodeURIComponent( wgTitle );     addPortletLink("p-cactions", wgServer + "/index.php?title=Special:Log&type=block&user=" + username, "Blocks given", "", "Blocks by this user");

} });