
/* menu */

// Some variables
var base= "images/m_"
var nrm = new Array();
var omo = new Array();
var stuff = new Array('about','events','office','home','lageplan','kontakt','english','i-lageplan','i-kontakt','i-agenda','i-english','i-wm10');
var loaded = (!(navigator.userAgent.indexOf('Netscape6')+1));
var ocl = new Array();
var select = -1;
var name2 = "";
var temp = 0;

// Pre-load part.
if (document.images)
{ for (i=0;i<stuff.length;i++)
    {nrm[i] = new Image;
    nrm[i].src = base + stuff[i] + ".gif"
    omo[i] = new Image;
    omo[i].src = base + stuff[i] + "-a.gif";
	ocl[i] = new Image;
	ocl[i].src = base + stuff[i] + "-a.gif"; }
}

// The functions: first mouseover, then mouseout
function over(no)
{	if (document.images && select != no && loaded)
    { document.images[stuff[no]].src = omo[no].src }
}

function out(no)
{	if (document.images && select != no && loaded)
    { document.images[stuff[no]].src = nrm[no].src }
}

function clic(no)
{ if (document.images && loaded)
	{ document.images[stuff[no]].src = ocl[no].src
	temp = select;
	select = no;
	if (temp != -1) {out(temp)} }
}



/* bilder öffner */

function OpenNewWindow(Picture,Breit,Hoch)
{
xsize = Breit+30;
ysize = Hoch+50;
    
ScreenWidth = screen.width;
ScreenHeight = screen.height;

xpos = (ScreenWidth/3)-(xsize/3);
ypos = (ScreenHeight/3)-(ysize/3);
	
NewWindow=window.open("","Picture","height="+ysize+",width="+xsize+",scrollbars=no,resizable=no,top="+ypos+",left="+xpos+"");
NewWindow.document.write ("<html><head><title> World Trade Center Zürich ");
NewWindow.document.write ("</title><link rel='stylesheet' type='text/css' href='wtc.css'></head>");
NewWindow.document.write ("<body bgcolor='#F6F6F6' topmargin='0' leftmargin='0' marginheight='0' marginwidth='0' bodymargin='0'>");
NewWindow.document.write ("<table align='center'><tr>");
NewWindow.document.write ("<td colspan='2' align='center' valign='top'>");
NewWindow.document.write ("<table border='0' cellpadding='0' cellspacing='0'><tr><td align='center'>");
NewWindow.document.write ("&nbsp;<br><img src=");
NewWindow.document.write (Picture);
NewWindow.document.write (" class='border'>");
NewWindow.document.write ("</tr></td></table>");
NewWindow.document.write ("</td></tr><tr>");
NewWindow.document.write ("<td><a href='javascript:window.print()' class=''>drucken</a></td>");
NewWindow.document.write ("<td align='right'><a href='javascript:top.window.close()'>schliessen</a></td>");
NewWindow.document.write ("</tr></table>");
NewWindow.document.write ("</body></html>");
NewWindow.document.close();
}

total_ads=4;
function ad() {
	ad_id=Math.floor(Math.random() * total_ads)+1;
	document.write('<img src="/images/inserat_'+ad_id+'.jpg" alt="" border="0">');
}

