//ERROR = NO ERROR
function ignoreErrors() {
return true;
}
window.onerror = ignoreErrors;

//alert('NEIIIIIIIIIIIN');
	function ChangeCover() {
  document.getElementById("1").style.background.src = "../img/bttn/bttn_1.jpg"; 
}
	function ChangeCout() {
  document.getElementById("1").style.backgroundColor = "#00FF00";
}
	function ChangeClick() {
  document.getElementById("1").style.backgroundColor = "#0000FF";
}
//DISPLAY INFO
var default_txt = "MASTERCLASS.DE :: Information...";
function displayX(text) {
  document.getElementById("displayX").innerHTML = text;
}
//NAVIGATION SCHUTZ
function navMove(){
  var navStat =  document.getElementById("navclap").innerHTML;
	if(navStat=='<a href="javascript:void(0);" onclick="navMove();">&lt;</a>'){
  document.getElementById("navclap").style.backgroundImage = "url(img/box/navbalk_off.gif)";
	document.getElementById("navclap").innerHTML = '<a href="javascript:void(0);" onclick="navMove();">&gt;</a>';	
	}else{
	document.getElementById("navclap").style.backgroundImage = "url(img/box/navbalk.gif)";
	document.getElementById("navclap").innerHTML = '<a href="javascript:void(0);" onclick="navMove();">&lt;</a>';
	}
}



wmtt = null;

function showWMTT(id) {
	wmtt = document.getElementById(id);
	wmtt.style.display = "block"
}
document.onmousemove = updateWMTT;

function updateWMTT(e) {
	x = (document.all) ? window.event.x + document.body.scrollLeft : e.pageX;
	y = (document.all) ? window.event.y + document.body.scrollTop  : e.pageY;
	if (wmtt != null) {
		wmtt.style.left = (x + 10) + "px";
		wmtt.style.top 	= (y + 15) + "px";
	}
}
function hideWMTT() {
	wmtt.style.display = "none";
}
//TOOLTIP EOF

//Externe Links kennzeichnen
var mydomain = document.location.host;
//alert('DOM: '+mydomain);
var extimagesrc = "img/icon/ext_link.gif";
var extimageoversrc = "img/icon/ext_link_over.gif";

function isExternLink(host) {
	if (host == "" || host == "www.spreadfirefox.com" || host == "www.masterclass.de" || host == "creativecommons.org" || host == "www.seomoz.org" || host == "www.mister-wong.de" || host == "validator.w3.org" || host == "jigsaw.w3.org") return false;
	var expr = new RegExp(mydomain, "i");
	if (expr.test(host)) return false;
	return true;
}

function init() {
  enableTooltips("content"); //TOOLTIP
	var alllinks = document.getElementsByTagName("a");

	for (var i = 0; i < alllinks.length; i++) {
		if (isExternLink(alllinks[i].host)) {
			var extimg = document.createElement("img");
			extimg.src = extimagesrc;
			extimg.width = 12;
			extimg.height = 12;
			extimg.title = "Externen Link in einem neuen Fenster öffnen.";
			if (!document.all) extimg.style.cursor = "pointer";
			extimg.longDesc = alllinks[i].href;
			extimg.onmouseover = function() {
				this.src = extimageoversrc;
			}
			extimg.onmouseout = function() {
				this.src = extimagesrc;
			}
			extimg.onclick = function() {
				window.open(this.longDesc);
			}
			alllinks[i].parentNode.insertBefore(extimg, alllinks[i]);
		}
	}
}
//Externe Links kennzeichnen EOF
