﻿$(function() {
		
		// run by defualt
		toggleScript();
		
		$(document).keypress(function(e){
			if (e.which == 71 && e.altKey) { // shift + alt + g
				toggleScript();
			};
		});

});

function toggleScript() {
	// Any kind of function to help detect problems on the page
	// while in development and to be removed before going live.
	//$('img:not([alt])').toggleClass('addAlt');
	
	//temporary indicator that there are links to the old site.
	( lnks = $("a") ).filter(function() {
			return this.hostname && this.hostname === ("h2o2.mojoactive.com" || "h2o2.mojoactive.local");
	}).toggleClass("toOldSite").attr("title", "Check External Link");
	
	//temporary indicator that there are links that havn't been finalized
	//lnks.filter("[href='/err']").toggleClass("addLink").attr("title", "Add Link");
	lnks.filter("[href*='/err']").toggleClass("addLink").attr("title", "Add Link");
}