///////////////////////////////////////////////////////////////
//Menu script copyright 2003 for Playspace Playground Pty Ltd//
///////////////////////////////////////////////////////////////


	//Detect user's browser and define type to browsertype var
		if (navigator.userAgent.indexOf("Opera")!=-1 && document.getElementById) browsertype="opera"
		if (document.all) browsertype="iexplore"
		if (document.layers) browsertype ="netscape"
		if (!document.all && document.getElementById) browsertype ="mozilla"

	//Define list of menus
		var menuitems = new Array("menu_wwwplayspace","menu_productranges","menu_e-brochures","menu_playgroundofthemonth","menu_playgrounds","menu_contactingplayspace");

	//Create the dynamic menu function
		function showmenu ( menuname )
			{
				if ((document.getElementById( menuname ).style.visibility) == "visible") //Check if selected menu is visible. If so, do not bother to continue
					{}
				else if ((document.getElementById( menuname ).style.visibility) == "hidden") //If the selected menu was NOT visible, run this to check and make sure that it is hidden.
					{
						//Begin to check and change all menu layers to hidden
							for (i=0;i<menuitems.length;i++){
								if ((document.getElementById(menuitems[i]).style.visibility) == "visible")
									{
										if (browsertype=="iexplore") document.all[menuitems[i]].style.visibility="hidden";
										if (browsertype=="netscape") document[menuitems[i]].style.visibility="hidden";
										if (browsertype=="mozilla") eval("document.getElementById(menuitems[i]).style.visibility='hidden'");
										if (browsertype=="opera") eval("document.getElementById(menuitems[i]).style.visibility='hidden'");
									}
					}

					// Display correct menu layer
						if (browsertype=="iexplore") document.all[menuname].style.visibility="visible"
						if (browsertype=="netscape") document[menuname].style.visibility="visible";
						if (browsertype=="mozilla") eval("document.getElementById(menuname).style.visibility='visible'");
						if (browsertype=="opera") eval("document.getElementById(menuname).style.visibility='visible'");
						if (browsertype=="iexplore"){
							eval("document.all['pleaseselectfrommenu'].style.visibility = 'visible';");
							setTimeout("document.all['pleaseselectfrommenu'].style.visibility = 'hidden';",3000)
							}
						if (browsertype=="netscape"){
							eval("document.['pleaseselectfrommenu'].style.visibility = 'visible';");
							setTimeout("document.['pleaseselectfrommenu'].style.visibility = 'hidden';",3000)
							}
						if (browsertype=="mozilla"){
							eval("document.getElementById('pleaseselectfrommenu').style.visibility = 'visible';");
							setTimeout("document.getElementById('pleaseselectfrommenu').style.visibility = 'hidden';",3000)
							}
						if (browsertype=="opera"){
							eval("document.getElementById('pleaseselectfrommenu').style.visibility = 'visible';");
							setTimeout("document.getElementById('pleaseselectfrommenu').style.visibility = 'hidden';",3000)
							}
						
					}
			}

	//Script for componentselect
	function showorhidelist ( divid )
		{
		if ((document.getElementById( divid ).style.visibility) == "visible")
			{
				if (browsertype=="iexplore") document.all[ divid ].style.visibility="hidden";
				if (browsertype=="netscape") document[ divid ].style.visibility="hidden";
				if (browsertype=="mozilla") eval("document.getElementById( divid ).style.visibility='hidden'");
				if (browsertype=="opera") eval("document.getElementById( divid ).style.visibility='hidden'");
			}
			else
			{
				if (browsertype=="iexplore") document.all[ divid ].style.visibility="visible";
				if (browsertype=="netscape") document[ divid ].style.visibility="visible";
				if (browsertype=="mozilla") eval("document.getElementById( divid ).style.visibility='visible'");
				if (browsertype=="opera") eval("document.getElementById( divid ).style.visibility='visible'");
			}
		}

	function thelist_pleasewait ( divid )
		{
				if (browsertype=="iexplore") document.all[ divid ].style.visibility="visible";
				if (browsertype=="netscape") document[ divid ].style.visibility="visible";
				if (browsertype=="mozilla") eval("document.getElementById( divid ).style.visibility='visible'");
				if (browsertype=="opera") eval("document.getElementById( divid ).style.visibility='visible'");

				if (browsertype=="iexplore") document.all[ divid ].style.visibility="hidden";
				if (browsertype=="netscape") document[ divid ].style.visibility="hidden";
				if (browsertype=="mozilla") eval("document.getElementById( divid ).style.visibility='hidden'");
				if (browsertype=="opera") eval("document.getElementById( divid ).style.visibility='hidden'");
		}



function showhelp ()
	{
	setTimeout("document.all['help1'].style.filter='alpha(opacity=0)'",5);
	setTimeout("document.all['help1'].style.visibility='visible'",10);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=10)'",250);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=20)'",400);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=30)'",650);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=40)'",900);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=50)'",1050);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=60)'",1100);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=70)'",1250);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=80)'",1500);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=100)'",1800);
	setTimeout("hidehelp1()",4000);
	}
function hidehelp1 ()
	{
	setTimeout("document.all['help1'].style.filter='alpha(opacity=95)'",250);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=90)'",500);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=80)'",750);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=70)'",1000);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=60)'",1250);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=50)'",1500);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=40)'",1750);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=30)'",2000);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=20)'",225000);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=10)'",2500);
	setTimeout("document.all['help1'].style.filter='alpha(opacity=5)'",2650);
	setTimeout("document.all['help1'].style.visibility='hidden'",2700);
	setTimeout("showhelp2()",3000);
	}


function showhelp2 ()
	{
	setTimeout("document.all['help2'].style.filter='alpha(opacity=0)'",5);
	setTimeout("document.all['help2'].style.visibility='visible'",10);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=10)'",250);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=20)'",400);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=30)'",550);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=40)'",700);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=50)'",1250);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=60)'",1500);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=70)'",1750);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=80)'",2000);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=90)'",225000);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=100)'",2500);
	setTimeout("hidehelp2()",6000);
	}


function hidehelp2 ()
	{
	setTimeout("document.all['help2'].style.filter='alpha(opacity=95)'",250);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=90)'",500);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=80)'",750);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=70)'",1000);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=60)'",1250);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=50)'",1500);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=40)'",1750);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=30)'",2000);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=20)'",225000);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=10)'",2500);
	setTimeout("document.all['help2'].style.filter='alpha(opacity=5)'",2580);
	setTimeout("document.all['help2'].style.visibility='hidden'",2640);

	}


function panel ( blahname )
	{

		if (browsertype=="iexplore") document.all['piratepanel'].style.visibility="hidden";
		if (browsertype=="iexplore") document.all['catpanel'].style.visibility="hidden";
		if (browsertype=="iexplore") document.all['cowpanel'].style.visibility="hidden";
		if (browsertype=="iexplore") document.all['penguinpanel'].style.visibility="hidden";

		if (browsertype=="iexplore") document.all[blahname].style.visibility="visible";
	}