function popup(text,x,y) {
	self.name="main"
	w = screen.availWidth/2 - x/2
	h = screen.availHeight/2 - y/2
	if (screen.availHeight < 800) {
		h = h + 50
	}
	var popup_popup = window.open( text+".html", "popup", "toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=no,width="+x+",height="+y+",screenX="+w+",screenY="+h+"")
	popup_popup.focus()
}

function contact(text,x,y) {
	self.name="main"
	w = screen.availWidth/2 - x/2
	h = screen.availHeight/2 - y/2
	if (screen.availHeight < 800) {
		h = h + 50
	}
	var contact_popup = window.open( text+".html", "contact", "toolbar=no,location=no,status=no,menubar=no,scrollbars=no,resizable=no,width="+x+",height="+y+",screenX="+w+",screenY="+h+"")
	contact_popup.focus()
}

function centerwindow() {
	//window.moveTo(screen.availWidth/2 - window.outerWidth/2 , screen.availHeight/2 - window.outerHeight/2)
}

function art(text,x,y) {

	self.name="main"
	w = screen.availWidth/2 - x/2
	h = ( screen.availHeight/2 - y/2)
	if (screen.availHeight < 800) {
		h = h + 50
	}
	var art_popup = window.open( text+".html", "art", "toolbar=0,location=no,status=no,menubar=no,scrollbars=no,location=no,resizable=no,width="+x+",height="+y+",screenX="+w+",screenY="+h+"")
}

function fitPic(w,h) {
	var browser=navigator.appName;
	if (browser == "Microsoft Internet Explorer") {
		w = w + 10;
		h = h + 60;
	}
	window.resizeTo(w,h);
	window.focus()
}
