// -----------------------------------------------------------------------
// START: Functions
// -----------------------------------------------------------------------

function exthtmlShow (aw,ah,url) 
{
	exthtml=window.open(url,"exthtml","screenX=150,left=150,screenY=150,top=150,location=no,directories=no,status=no,scrollbars=yes,resizable=no,copyhistory=no,menubar=no,toolbar=no,width="+aw+",height="+ah+"");
	exthtml.focus();
}

function floaterShow (aw,ah,url) 
{
	// scrollbars = yes
	// resizable = no
	// menubar, toolbar = no
	exthtml=window.open(url,"exthtml","screenX=150,left=150,screenY=150,top=150,location=no,directories=no,status=no,scrollbars=yes,resizable=no,copyhistory=no,menubar=no,toolbar=no,width="+aw+",height="+ah+"");
	exthtml.focus();
}

function floaterShow3 (aw,ah,url) 
{
	// scollbars = no
	// resizable = no
	// menubar, toolbar = no
	exthtml=window.open(url,"exthtml","screenX=150,left=150,screenY=150,top=150,location=no,directories=no,status=no,scrollbars=no,resizable=no,copyhistory=no,menubar=no,toolbar=no,width="+aw+",height="+ah+"");
	exthtml.focus();
}

function floaterShow2 (aw,ah,url) 
{
	// scrollbars = yes
	// resizable = yes
	// menu, toolbar = yes, no
	exthtml=window.open(url,"exthtml","screenX=150,left=150,screenY=150,top=150,location=no,directories=no,status=no,scrollbars=yes,resizable=yes,copyhistory=no,menubar=yes,toolbar=no,width="+aw+",height="+ah+"");
	exthtml.focus();
}

function extpicShow (aw,ah,iw,ih,iurl,windowtitle) {
	extpic=window.open("","extpic","toolbar=no,screenX=100,left=100,screenY=100,top=100,location=no,directories=no,status=no,scrollbars=no,resizable=no,copyhistory=no,menubar=no,width="+aw+",height="+ah+"");
	extpic.document.close();
	extpic.document.write("<HEAD><TITLE>"+windowtitle+"</TITLE></HEAD><BODY BGCOLOR=#FFFFFF topmargin=0 leftmargin=0 marginwidth=0 marginheight=0><center><a href='javascript:self.close();'><IMG SRC='"+iurl+"' width='"+iw+"' height='"+ih+"' border='0'></a></center></BODY>");
	extpic.focus();
}

function extrefShow(aw,ah,imagehref,projecttitle,copyheadline,copytext)
{
	extflash = window.open("","extflash","screenX=70,left=70,screenY=70,top=70,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizeable=no,copyhistory=no,width="+aw+",height="+ah+"");
	extflash.document.close();
	extflash.document.write("<HEAD><TITLE>"+projecttitle+"</TITLE><link href='/career_style.css' rel='styleSheet' type='text/css'></HEAD>");
    extflash.document.write("<BODY BGCOLOR=#FFFFFF topmargin=15 leftmargin=15 marginwidth=15 marginheight=15>");		
	extflash.document.write("<a href='javascript:window.close();'><IMG SRC='"+imagehref+"' border=0></a><br><img src='/media/ca_system/sp_trans.gif' width=1 height=10><br>");
	extflash.document.write("<span class=headlineone>"+copyheadline+"</span><br><img src='/media/ca_system/sp_trans.gif' width=1 height=6><br>");
	extflash.document.write("<span class=copytext>"+copytext+"</span><br><img src='/media/ca_system/sp_trans.gif' width=1 height=10><br>");
	extflash.document.write("</BODY>");
	extflash.focus();
}

function extrefFlashShow(aw,ah,iw,ih,flashhref,projecttitle)
{
	extflash = window.open("","extflash","screenX=70,left=70,screenY=70,top=70,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizeable=yes,copyhistory=no,width="+aw+",height="+ah+"");
	extflash.document.close();
	extflash.document.write("<HEAD><TITLE>"+projecttitle+"</TITLE><link href='/career_style.css' rel='styleSheet' type='text/css'></HEAD>");
    extflash.document.write("<BODY BGCOLOR=#FFFFFF topmargin=0 leftmargin=0 marginwidth=0 marginheight=0>");		
	extflash.document.write("<OBJECT WIDTH="+iw+" HEIGHT="+ih+"><PARAM NAME=movie VALUE='"+flashhref+"'> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF><EMBED src='"+flashhref+"' quality=high bgcolor=#FFFFFF WIDTH="+iw+" HEIGHT="+ih+" TYPE='application/x-shockwave-flash'></EMBED></OBJECT>");
	extflash.document.write("</BODY>");
	extflash.focus();
}

function setMainWindow (url) 
{
	opener.location = url;
}

function setMainWindowAndClose (url) 
{
	opener.location = url;
	self.close();
}

function newImage(arg) {
	if (document.images) {
		rslt = new Image();
		rslt.src = arg;
		return rslt;
	}
}

function changeImages() {
	if (document.images && (preloadFlag == true)) {
		for (var i=0; i < changeImages.arguments.length; i+=3) {
			document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
		}
	}
}

var preloadFlag = false;
	
function preloadImages() {
	if (document.images) {
			// preload pics
			zf_de_public_actv = newImage("/media/zf_navigation/de_topnav_public_actv.gif");
			zf_de_events_actv = newImage("/media/zf_navigation/de_topnav_events_actv.gif");
			zf_de_artists_actv = newImage("/media/zf_navigation/de_topnav_artists_actv.gif");
			zf_de_photo_actv = newImage("/media/zf_navigation/de_topnav_photo_actv.gif");
			zf_de_guestbook_actv = newImage("/media/zf_navigation/de_topnav_guestbook_actv.gif");
			zf_de_links_actv = newImage("/media/zf_navigation/de_topnav_links_actv.gif");
			zf_de_contact_actv = newImage("/media/zf_navigation/de_topnav_contact_actv.gif");
			preloadFlag = true;
		}
	}


function imgactivate(currentitem,imgtoshow,currentPage)
{
	if (document.images && (preloadFlag == true)) {
		if (currentPage != currentitem) { 
			document[currentitem].src = imgtoshow; 
		}
	}
}

function imgdeactivate(currentitem, imgtoshow, currentPage)
{
	if (currentPage != currentitem) { document[currentitem].src = imgtoshow; }
}


// -----------------------------------------------------------------------
// END: Functions
// -----------------------------------------------------------------------
