User:Inquisitor Sasha/mikalBlockLog.js

From RationalWiki
Jump to navigation Jump to search

Note: After saving, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files.
/*
 
MIKAL LOG BUTTON
 
AUTHOR: Inquisitor Ehrenstein
CONTRIBUTORS:
DESCRIPTION: Adds a button to the userbar links at the top for checking Mikal's block log.

*/

var mlRef = document.getElementById('pt-logout');
var mlParent = mlRef.parentNode;
var mlNewLink = document.createElement('li');
 
mlNewLink.id = 'mikal-log';
mlNewLink.innerHTML = '<a style="font-size: 9pt; border: 1px solid #777777; background: #CCCCCC; padding-left: 10px; padding-right: 10px; padding-top: 2px; padding-bottom: 2px;" href="http://rationalwiki.org/w/index.php?title=Special%3ALog&type=block&user=Mikal&page=&year=&month=-1&tagfilter=&hide_patrol_log=1"><b>Log</b></a>';
 
mlParent.insertBefore(mlNewLink, mlRef);