// Orange nav v1.0
// written by Stephen Brown
// AKQA
// 10th Novemeber 2000

// this nav includes the following functions:

// 	create_menus
// 	show_menu
// 	hide_menu
// 	show_sub
// 	hide_sub
// 	hide_all
// 	menuOver
// 	menuOut
// 	ns_hidehilights
// 	set_timeout
// 	clear_timer
// 	write_nav

// the following functions will show / hide Flash Animations
// when the navigation menu opens:

// 	show_flash
// 	hide_flash
// 	start_layer
// 	end_layer

// 	MouseOver
// 	MouseOut

// Cookie for Home Page to say "Back Again"
// 	SetHomeCookie

// netscape / IE 3 and less detect
// nsie3_det

// setting up new Arrays for Orange dHTML menu 


var isNC6;

if((navigator.appName == "Netscape") && (parseInt(navigator.appVersion.charAt(0))>4)) {

	isNC6 = true; }

function create_menus()
{
	args = create_menus.arguments;
	var ID = args[0];
	var direction;

	if(document.all || isNC6)
	// Internet Explorer Menu
	{
		for(i=0; i<dMenu[ID].length; i++)
		{
			
			direction=dSubMenu[ID].direction=="left"?"left":"right";
			document.write('<DIV ID="dNav'+ID+i+'" STYLE="z-index:100; background:#D71730; position:absolute; visibility:hidden; left:'+dMenu[ID].left+'; top:'+dMenu[ID].top+'; width:'+dMenu[ID].width+'; height:20;" OnMouseOver="menuOver('+ID+','+i+');" OnMouseOut="menuOut('+ID+','+i+');" OnClick="document.location.href=\''+dMenu[ID].links[i]+'\';">');
			document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dMenu[ID].width+'" CLASS="whitelink">\n');
			document.write('<TR><TD VALIGN="TOP">');
			if(dSubMenu[ID][i][0] && direction == "left")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			document.write('</TD><TD VALIGN="TOP" NOWRAP>');
			document.write('<IMG SRC="/images/clear.gif" WIDTH="'+(dMenu[ID].width-20)+'" HEIGHT=2 BORDER=0><BR>');
			document.write('<FONT CLASS="whitelink">');
			document.write(dMenu[ID][i]);
			document.write('</FONT>');
			document.write('</TD><TD>');
			if(dSubMenu[ID][i][0] && direction == "right")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			document.write('</TD></TR>\n');
			document.write('</TABLE>\n');
			document.write('</DIV>\n');

			// Sub Menu Generation
			if(dSubMenu[ID][i][0])
			{
				var top=dMenu[ID].top;
				for(j=0; j<dSubMenu[ID][i].length; j++)
				{
					var submenuleft=(dMenu[ID].left+dMenu[ID].width);
					if(direction == "left")
					{
						submenuleft=(dMenu[ID].left-dSubMenu[ID].width);
					}
					document.write('<DIV ID="dNav'+ID+i+'O'+j+'" STYLE="z-index:100; background:#D71730; position:absolute; visibility:hidden; left:'+submenuleft+'; top:'+top+'; width:'+dSubMenu[ID].width+'; height:20;" OnMouseOver="menuOver('+ID+','+i+','+j+');" OnMouseOut="menuOut('+ID+','+i+','+j+');" OnClick="document.location.href=\''+dSubMenu[ID][i].links[j]+'\';">');
					document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dSubMenu[ID].width+'" CLASS="whitelink">\n');
					document.write('<TR><TD VALIGN="TOP">');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
					document.write('</TD><TD VALIGN="TOP" NOWRAP>');
					document.write('<IMG SRC="/images/clear.gif" WIDTH="'+(dSubMenu[ID].width-20)+'" HEIGHT=2 BORDER=0><BR>');
					document.write('<FONT CLASS="whitelink">');
					document.write(dSubMenu[ID][i][j]);
					document.write('</FONT>');
					document.write('</TD><TD>');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
					document.write('</TD></TR>\n');
					document.write('</TABLE>\n');
					document.write('</DIV>\n');
					top+=20;
				}
			}
			dMenu[ID].top+=20;
		}
	}
	else if(document.layers)
	// Netscape Navigator/Communicator Menu
	{
		for(i=0; i<dMenu[ID].length; i++)
		{
			direction=dSubMenu[ID].direction=="left"?"left":"right";
			var nsdirection=(dMenu[ID].nsdirection)?dMenu[ID].nsdirection:"left";

			// Navigation Menu Item
			document.write('<LAYER NAME="dNav'+ID+i+'" Z-INDEX="100" BGCOLOR="#D71730" POSITION="absolute" VISIBILITY="hide" LEFT="'+dMenu[ID].nsleft+'" TOP="'+dMenu[ID].top+'" WIDTH="'+dMenu[ID].nswidth+'" HEIGHT="20" OnMouseOver="menuOver('+ID+','+i+');" OnMouseOut="menuOut('+ID+','+i+');">\n');
			document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dMenu[ID].nswidth+'">\n');
			document.write('<TR><TD VALIGN="TOP">');
			if(dSubMenu[ID][i][0] && direction == "left")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			document.write('</TD><TD VALIGN="TOP" NOWRAP ALIGN="'+nsdirection+'">');
			document.write('<IMG SRC="/images/clear.gif" WIDTH="'+(dMenu[ID].nswidth-20)+'" HEIGHT=2 BORDER=0><BR>');
			document.write('<A HREF="/gr/javascript/%27+dMenu%5BID%5D.links%5Bi%5D+%27" CLASS="whitelink">');
			document.write(dMenu[ID][i]);
			document.write('</A>');
			document.write('</TD><TD>');
			if(dSubMenu[ID][i][0] && direction == "right")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			document.write('</TD></TR>\n');
			document.write('</TABLE>\n');
			document.write('</LAYER>\n');
			
			// Over Navigation Menu Item
			document.write('<LAYER NAME="dNav'+ID+i+'Over" Z-INDEX="100" BGCOLOR="#000000" POSITION="absolute" VISIBILITY="hide" LEFT="'+dMenu[ID].nsleft+'" TOP="'+dMenu[ID].top+'" WIDTH="'+dMenu[ID].nswidth+'" HEIGHT="20" OnMouseOver="menuOver('+ID+','+i+');" OnMouseOut="menuOut('+ID+','+i+');">\n');
			document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dMenu[ID].nswidth+'">\n');
			document.write('<TR><TD VALIGN="TOP">');
			if(dSubMenu[ID][i][0] && direction == "left")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
			}
			document.write('</TD><TD VALIGN="TOP" NOWRAP ALIGN="'+nsdirection+'">');
			document.write('<IMG SRC="/images/clear.gif" WIDTH="'+(dMenu[ID].nswidth-20)+'" HEIGHT=2 BORDER=0><BR>');
			document.write('<A HREF="/gr/javascript/%27+dMenu%5BID%5D.links%5Bi%5D+%27" CLASS="whitelink">');
			document.write(dMenu[ID][i]);
			document.write('</A>');
			document.write('</TD><TD>');
			if(dSubMenu[ID][i][0] && direction == "right")
			{
				document.write('<IMG SRC="/images/'+direction+'_tri.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			else
			{
				document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
			}
			document.write('</TD></TR>\n');
			document.write('</TABLE>\n');
			document.write('</LAYER>\n');
			
			if(dSubMenu[ID][i].length)
			{
				var top=dMenu[ID].top;
				for(j=0; j<dSubMenu[ID][i].length; j++)
				{
					var submenuleft=(dMenu[ID].nsleft+dMenu[ID].nswidth);
					if(direction == "left")
					{
						submenuleft=(dMenu[ID].nsleft-dSubMenu[ID].nswidth);
					}
					// Navigation Menu Item
					document.write('<LAYER NAME="dNav'+ID+i+'O'+j+'" Z-INDEX="100" BGCOLOR="#D71730" POSITION="absolute" VISIBILITY="hide" LEFT="'+submenuleft+'" TOP="'+top+'" WIDTH="'+dSubMenu[ID].nswidth+'" HEIGHT="20" OnMouseOver="menuOver('+ID+','+i+','+j+');">\n');
					document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dSubMenu[ID].nswidth+'">\n');
					document.write('<TR><TD VALIGN="TOP">');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
					document.write('</TD><TD VALIGN="TOP" NOWRAP>');
					document.write('<IMG SRC="/images/clear.gif" WIDTH="'+(dSubMenu[ID].nswidth-20)+'" HEIGHT=2 BORDER=0><BR>');
					document.write('<A HREF="/gr/javascript/%27+dSubMenu%5BID%5D%5Bi%5D.links%5Bj%5D+%27" CLASS="whitelink">');
					document.write(dSubMenu[ID][i][j]);
					document.write('</A>');
					document.write('</TD><TD>');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
					document.write('</TD></TR>\n');
					document.write('</TABLE>\n');
					document.write('</LAYER>');

					// Over Navigation Menu Item
					document.write('<LAYER NAME="dNav'+ID+i+'O'+j+'Over" Z-INDEX="100" BGCOLOR="#000000" POSITION="absolute" VISIBILITY="hide" LEFT="'+submenuleft+'" TOP="'+top+'" WIDTH="'+dSubMenu[ID].nswidth+'" HEIGHT="20" OnMouseOut="menuOut('+ID+','+i+','+j+');">\n');
					document.write('<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH="'+dSubMenu[ID].nswidth+'">\n');
					document.write('<TR><TD VALIGN="TOP">');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=20 BORDER=0>');
					document.write('</TD><TD VALIGN="TOP" NOWRAP>');
					document.write('<IMG SRC="/gr/javascript/images/clear.gif" WIDTH="'+(dSubMenu[ID].nswidth-20)+'" HEIGHT=2 BORDER=0><BR>');
					document.write('<A HREF="/gr/javascript/%27+dSubMenu%5BID%5D%5Bi%5D.links%5Bj%5D+%27" CLASS="whitelink">');
					document.write(dSubMenu[ID][i][j]);
					document.write('</A>');
					document.write('</TD><TD>');
					document.write('<IMG SRC="/images/clear.gif" WIDTH=10 HEIGHT=19 BORDER=0>');
					document.write('</TD></TR>\n');
					document.write('</TABLE>\n');
					document.write('</LAYER>');
					top+=20;
				}
			}
			dMenu[ID].top+=20;
		}
	}
}

function show_menu(menu)
{
	
	hide_all(0);
	if(document.layers) ns_hidehilights(menu);
	
	clear_timer();
	if(document.all)
	{
		for(i=0; i<dMenu[menu].length; i++)
		{
			document.all['dNav'+menu+i].style.visibility='visible';
		}
	}
	if(isNC6) {
		
		for(i=0; i<dMenu[menu].length; i++)
		{
			document.getElementById('dNav'+menu+i).style.visibility='visible';
		}
	}
	else if(document.layers)
	{
		for(i=0; i<dMenu[menu].length; i++)
		{
			document.layers['dNav'+menu+i].visibility='show';
		}
	}
}

function hide_menu(menu)
{
	if(document.all)
	{
		for(i=0; i<dMenu[menu].length; i++)
		{
			document.all['dNav'+menu+i].style.visibility='hidden';
		}
	}
	if(isNC6) {
		//clearTimeout(closewindows);
		for(i=0; i<dMenu[menu].length; i++){			
			document.getElementById("dNav"+menu+i).style.visibility='hidden';
		}
	return menu;
	//set_timer();
	}
	else if(document.layers)
	{
		for(i=0; i<dMenu[menu].length; i++)
		{
			document.layers['dNav'+menu+i].visibility='hide';
			document.layers['dNav'+menu+i+'Over'].visibility='hide';
		}
	}
	return menu;
}

function show_sub(menu,item)
{
	if(document.all && dSubMenu[menu][item][0] != "undefined")
	{
		for(i=0; i<dSubMenu[menu][item].length; i++)
		{
			document.all['dNav'+menu+item+'O'+i].style.visibility='visible';
		}
		document.all['dNav'+menu+item].style.background="#000000";
	}
	if(isNC6 && dSubMenu[menu][item][0] != "undefined")
	{
		for(i=0; i<dSubMenu[menu][item].length; i++)
		{
			document.getElementById('dNav'+menu+item+'O'+i).style.visibility='visible';
		}
		document.getElementById('dNav'+menu+item).style.background="#000000";
	}
	else if(document.layers && dSubMenu[menu][item][0] != "undefined")
	{
		for(i=0; i<dSubMenu[menu][item].length; i++)
		{
			document.layers['dNav'+menu+item+'O'+i].visibility='show';
		}
	}
}

function hide_sub(menu,item)
{
	if(document.all)
	{
		if(document.all['dNav'+menu+item+'O'+'0'])
		{
			for(i=0; i<dSubMenu[menu][item].length; i++)
			{
				document.all['dNav'+menu+item+'O'+i].style.visibility='hidden';
			}
			document.all['dNav'+menu+item].style.background="#D71730";
		}
	}
	if(isNC6)
	{
		if(document.getElementById("dNav"+menu+item+"O"+"0"))	{
			
			for(i=0; i<dSubMenu[menu][item].length; i++)
			{
				document.getElementById('dNav'+menu+item+'O'+i).style.visibility='hidden';
			}
			document.getElementById('dNav'+menu+item).style.background="#D71730";
		}
	}
	else if(document.layers)
	{
		if(document.layers['dNav'+menu+item+'O'+'0'])
		{
			for(i=0; i<dSubMenu[menu][item].length; i++)
			{
				document.layers['dNav'+menu+item+'O'+i].visibility='hide';
				document.layers['dNav'+menu+item+'O'+i+'Over'].visibility='hide';
			}
		}
	}
	return item;
}

function hide_all(flash)
{
	for(i=0; i<dMenu.length; i++)
	{
		
		i = hide_menu(i);
		
	}
	var dsmi;
	
	for(k=0; k<dSubMenu.length; k++)
	{
		dsmi = dSubMenu[k].length;
		for(j=0; j<dsmi; j++)
		{
			hide_sub(k,j);
		}
	}
	
	if(flash) hide_flash()
	else show_flash();
	
}

function menuOver(menu,item,sub)
{
	if(document.layers) ns_hidehilights(menu,item);
	clear_timer();
	if(sub || sub == 0)
	{
		show_sub(menu,item);
		if(document.all)
		{
			document.all['dNav'+menu+item+'O'+sub].style.background="#000000";
		}
		if(isNC6)
		{
			document.getElementById('dNav'+menu+item+'O'+sub).style.background="#000000";
		}
		else if(document.layers)
		{
			document.layers['dNav'+menu+item+'O'+sub].visibility='hide';
			document.layers['dNav'+menu+item+'O'+sub+'Over'].visibility='show';
			document.layers['dNav'+menu+item+'Over'].visibility='show';
		}
	}
	else
	{
		if(document.all)
		{
			document.all['dNav'+menu+item].style.background="#000000";
			if(dMenu[menu][item].length>0)
			{
				hide_sub(openmenu,openitem);
				show_sub(menu,item);
			}
		}
		if(isNC6)
		{
			document.getElementById('dNav'+menu+item).style.background="#000000";
			if(dMenu[menu][item].length>0)
			{
				hide_sub(openmenu,openitem);
				show_sub(menu,item);
			}
		} 
		else if(document.layers)
		{
			document.layers['dNav'+menu+item].visibility='hide';
			document.layers['dNav'+menu+item+'Over'].visibility='show';
			if(dMenu[menu][item].length>0)
			{
				hide_sub(openmenu,openitem);
				show_sub(menu,item);
			}
		}
	}
	openmenu=menu;
	openitem=item;
}

function menuOut(menu,item,sub)
{
	if(document.layers) ns_hidehilights(menu,item);
	if(sub || sub == 0)
	{
		if(document.all)
		{
			document.all['dNav'+menu+item+'O'+sub].style.background="#D71730";
		}
		if(isNC6)
		{
			document.getElementById('dNav'+menu+item+'O'+sub).style.background="#D71730";
		} 
		else if(document.layers)
		{
			document.layers['dNav'+menu+item+'O'+sub].visibility='show';
			document.layers['dNav'+menu+item+'O'+sub+'Over'].visibility='hide';
			document.layers['dNav'+menu+item+'Over'].visibility='show';
		}
	}
	else
	{
		if(document.all)
		{
			document.all['dNav'+menu+item].style.background="#D71730";
			if(dMenu[menu][item].length>0)
			{
				hide_sub(menu,item);
			}
		}
		if(isNC6)
		{
			document.getElementById('dNav'+menu+item).style.background="#D71730";
			if(dMenu[menu][item].length>0)
			{
				hide_sub(menu,item);
			}
		}
		else if(document.layers)
		{
			document.layers['dNav'+menu+item].visibility='show';
			document.layers['dNav'+menu+item+'Over'].visibility='hide';
			if(dMenu[menu][item].length>0)
			{
				hide_sub(menu,item);
			}
		}
	}
	set_timeout();
}

function ns_hidehilights(menu,item)
{
	for(i=0; i<dMenu[menu].length; i++)
	{
		document.layers['dNav'+menu+i+'Over'].visibility='hide';
		document.layers['dNav'+menu+i].visibility='show';
	}
	
	if(item)
	{
		for(i=0; i<dSubMenu[menu][item].length; i++)
		{
			document.layers['dNav'+menu+item+'O'+i+'Over'].visibility='hide';
		}
	}
}

function set_timeout()
{
	closewindows = setTimeout('hide_all();',500);
}

function clear_timer(menu)
{
	clearTimeout(closewindows);
}

function write_nav() {
	if(document.all || document.layers || isNC6)
	{
		document.write('<TABLE CELLPADDING="0" CELLSPACING="0" BORDER="0" WIDTH="100%" HEIGHT="18">');
		document.write('<TR>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="17" BORDER="0" ALIGN="MIDDLE" ALT=""></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=0,0,0">Home</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="#" OnMouseOver="show_menu(0)" OnMouseOut="set_timeout(0);">Der Verein</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="#" OnMouseOver="show_menu(1);" OnMouseOut="set_timeout(1);">Funsport</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=3,0,0">Forum</A></TD>');		
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="#" OnMouseOver="show_menu(2)" OnMouseOut="set_timeout(2);">G&auml;stebuch</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="#" OnMouseOver="show_menu(3)" OnMouseOut="set_timeout(3);">Events</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=6,0,0">News</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=7,0,0">Racing Team</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=8,0,0">Gallery</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="#" OnMouseOver="show_menu(4)" OnMouseOut="set_timeout(0);">Presse</A></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"><IMG SRC="/images/left.gif" WIDTH="1" HEIGHT="17" BORDER="0"><IMG SRC="/images/clear.gif" WIDTH="5" HEIGHT="1" BORDER="0"></TD>');
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="CENTER" NOWRAP><A CLASS="whitelink" HREF="/index.php?ctid=10,0,0">Links</A></TD>');		
		document.write('<TD HEIGHT="17" VALIGN="MIDDLE" ALIGN="LEFT"><IMG SRC="/images/clear.gif" WIDTH="10" HEIGHT="1" BORDER="0"></TD>');
				
		document.write('</TR>');
		document.write('<TR>');
		document.write('<TD COLSPAN="16"><IMG SRC="/images/clear.gif" WIDTH="1" HEIGHT="1" BORDER="0"></TD>');
		document.write('</TR>');
		document.write('</TABLE>');
	}
	else
	{
		document.write('Your Browser is not Supported!');
		
	}
}

function show_flash()
{
	if(document.all)
	{
		for(fc=count-1; fc>=0; fc--)
		{
			params=FlashLayers[fc];
			document.all[params].style.visibility="visible";
		}
	}
	if(isNC6)
	{
		for(fc=count-1; fc>=0; fc--)
		{
			params=FlashLayers[fc];
			document.getElementById(params).style.visibility="visible";
		}
	}
	if(document.layers)
	{
		var params;
		for(fc=count-1; fc>=0; fc--)
		{
			params=FlashLayers[fc];
			document.layers[params].visibility="visible";
		}
	}
}

function hide_flash()
{
	if(document.all)
	{
		if(!count)
		{
			// Count Flash Layers
			for(params in document.all)
			{
				if(params.substring(0,5) == "Flash")
				{
					document.all[params].style.visibility="hidden";
					FlashLayers[count] = params;
					count++;
				}
			}
		}
		else
		{
			for(fc=count-1; fc>=0; fc--)
			{
				document.all[FlashLayers[fc]].style.visibility="hidden";
			}
		}
	}	
	if(document.layers)
	{
		if(!count)
		{
			// Count Flash Layers
			for(params in document.layers)
			{
				if(params.substring(0,5) == "Flash")
				{
					document.layers[params].visibility="hidden";
					FlashLayers[count] = params;
					count++;
				}
			}
		}
		else
		{
			for(fc=count-1; fc>=0; fc--)
			{
				document.layers[FlashLayers[fc]].visibility="hidden";
			}
		}
	}
}

function start_layer(layername,top,left)
{
	layername="Flash"+layername;
	if(document.layers)
	{
		if(top) { top = " TOP=\""+top+"\""; } else { top = " TOP=\"98\""; }
		if(left) { left = " LEFT=\""+left+"\""; } else { left = " LEFT=\"0\""; }
		document.write('<LAYER ID="'+layername+'" Z-INDEX="97" POSITION="absolute" '+top+left+'>');
	}
	else
	{
		if(!left) { left = 0; }
		document.write('<DIV ID="'+layername+'" STYLE="z-index:97; position:absolute; top:'+top+'; left:'+left+';">');
	}
}

function end_layer()
{
	if(document.layers)
	{
		document.write('</LAYER>');
	}
	else
	{
		document.write('</DIV>');
	}
}

function MouseOver(image)
{
	if (document.images[image].src.indexOf("-over") == -1)
	{
		document.images[image].src = document.images[image].src.substring(0,document.images[image].src.indexOf(".gif")) + "-over.gif";
	}
}

function MouseOut(image)
{
	if (document.images[image].src.indexOf("-over") != -1)
	{
		document.images[image].src = document.images[image].src.substring(0,document.images[image].src.indexOf("-over.gif")) + ".gif";
	}
}

function SetHomeCookie()
{
	var cookies = document.cookie.split("; ");
	for (i=0; i<cookies.length; ++i)
	{
		cookie=cookies[i].split("=");
		if(cookie[0].match("visited"))
		{
			return cookie[1];
		}
	}
	var exp = new Date();
	var oneweek = exp.getTime() + (7*24*60*60*1000);
	exp.setTime(oneweek);
	document.cookie="visited=1";
	return 0;
}

function nsie3_det()
{
var gotolocation=false;
	if(navigator.appName == "Netscape")
	{
		if(parseInt(navigator.appVersion) <= 3)
		{
			gotolocation=true;
		}
	}
	if(navigator.appName.match("Internet Explorer"))
	{
		if(parseInt(navigator.appVersion) <= 3)
		{
			gotolocation=true;
		}
	}
	if(gotolocation)
	{
		var currentURL=document.URL;
		for(i=0;i<3;i++)
		{
			currentURL=currentURL.substring(currentURL.indexOf("/")+1);
		}
		if(currentURL == "index.html" || currentURL == "")
		{
			window.open("/ns3.html","Orange","height=375,width=600");
			document.location.href="old_home.html";
		}
	}
}
nsie3_det();

var openmenu;
var openitem;
var closewindows;
var FlashLayers = new Array();
var count = 0;

var cleargif = new Image();
cleargif.src = "/images/clear.gif";
var personal = new Image();
personal.src = "/images/personal.gif";
var business = new Image();
business.src = "/images/business.gif";
var logo = new Image();
logo.src = "/images/logo.gif";
var line = new Image();
line.src = "/images/left.gif";
var leftarr = new Image();
leftarr.src = "/images/left_tri.gif";
var rightarr = new Image();
rightarr.src = "/images/right_tri.gif";