User:Davidgothberg/newmessageshistory.js

/***** New messages history ****************************************

Adds a "history" link to the "You have new messages" box.

See full documentation at User:Davidgothberg/newmessageshistory.

$( function {

var messtag = document.getElementById( "mw-youhavenewmessages" ); if ( messtag ) { var link = document.createElement( "a" ); link.appendChild( document.createTextNode( "history" ) ); link.href = mw.config.get('wgScript') + "?title=User_talk:" + mw.config.get('wgUserName') + "&action=history"; messtag.insertBefore( document.createTextNode( ", " ), messtag.lastChild ); messtag.insertBefore( link, messtag.lastChild ); } } ); /* End New messages history */