User:Technical 13/Scripts/ACCHelp/Block log.js

Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
if($("h1#firstHeading").text() === "Block log"){
	$("p:contains(\"No matching items in log.\")").addClass("error");
	if(typeof($("p:contains(\"No matching items in log.\")").html()) === "undefined"){
		var currDate = new Date();
		var expDate = $('td.TablePager_col_ipb_expiry').html().match(/([\d]{2}):([\d]{2}), (.*?) ([\d]{1,2}), ([\d]{4})/);
		for(var month in wgMonthNames){
			if(wgMonthNames[month] === expDate[3]){
				expDate[3] = month-1;
			}
		}
		expDate = new Date(expDate[5], expDate[3], expDate[4], expDate[1], expDate[2]);
		if(currDate < expDate){
			$("h1#firstHeading").html(tickBad + " " + $("h1#firstHeading").html());
			document.title = Ucross + document.title;
			alert("WARNING!\n\t\tThere is an active local block on:\n\n\t\t\t\t" + $("input#mw-log-page").val().substr(5));
		} else {
			$("h1#firstHeading").html(tickGood + " " + $("h1#firstHeading").html());
			document.title = Ucheck + document.title;
		}
		//$('td.TablePager_col_ipb_reason').html();//too tired to finish this.. good night.
	} else {
		$("h1#firstHeading").html(tickGood + " " + $("h1#firstHeading").html());
		document.title = Ucheck + document.title;
	}
}