//you can't show this website in your own frame!
if (top != self)
  top.location = self.location;
//thx 2 selfhtml :)

var stdWidth = 420;
var stdHeight = 600;
var zentrierenX = (screen.width/2)-(stdWidth / 2); 
var zentrierenY = (screen.height/2)-(stdHeight / 2); 
var pos = "left="+zentrierenX+", top="+zentrierenY; 

//Admin Popup Breite und Höhe sollen 80% vom Gesamten sein
var adminWidth = (screen.width * 0.8);
var adminHeight = (screen.height * 0.8);
var adminPos = "left=" + ((screen.width/2) - (adminWidth/2)) + ", top=0"; 

function stdPopup(adress, name) {
	var options = 'width=' + stdWidth + ', height=' + stdHeight + ', menubar=no, location=no, status=no, scrollbars=yes, resizable=no, toolbar=0, titlebar=0,  ' + pos;
	
	var stdwindow = window.open(adress, "", options);
	stdwindow.focus();
}

//if js is activated, a click should show a popup

function setLinkToPopup(id) {
	//var elem = getElement('id', id);
	var href = getAttribute("id", id, null, "href");
	//var href = document.createAttribute('href');
	//href.nodeValue = 'javascript: stdPopup(\'' +  + '\', \'' + popupid + '\');';
	//elem.setAttributeNode(href);
	alert(href.nodeValue);
}

function adminPopup(adress, name) {
	var options = 'width=' + adminWidth + ', height=' + adminHeight + ', menubar=no, location=no, status=no, scrollbars=yes, resizable=no, toolbar=0, titlebar=0, ' + adminPos;
	var adminwindow = window.open(adress, "", options);
	adminwindow.focus();
}
