
  //Link[nr] = "position [0 is menu/1 is item],Link name,url,target (blank|top|frame_name),0 is no drop down 1 drop down"

  var Link = new Array();

  Link[0] = "0|Home|index.html||0";
  Link[1] = "0|Aims & Objectives|aims.html||0";
  Link[2] = "0|The Team|||1";
  Link[3] = "1|Board of Directors|directors.html||0";
  Link[4] = "1|Honorary Members|honorary.html||0";
  Link[5] = "1|Professionals|professionals.html||0";
  Link[6] = "1|Staff|staff.html||0"
  Link[7] = "0|Carer Support|cs.html||0";
  Link[8] = "0|Events|||1";
  Link[9] = "1|Overview|overview.html||0";
  Link[10] = "1|Past Events|past.html||0";
  Link[11] = "1|Forthcoming Events|forthcoming.html||0";
  Link[12] = "0|Documents / Resources|resources.html||0";
  Link[13] = "0|Consultation Documents|consultations.html||0";
  Link[14] = "0|Training|training.html||0";
  Link[15] = "0|Location|location.html||0";
  Link[16] = "0|Contact|||1";
  Link[17] = "1|Details|details.html||0";
  Link[18] = "1|Other Organisations|otherorgs.html||0";
  Link[19] = "1|Issues & Concerns|issues.html||0";
  Link[20] = "1|Join|join.html||0";

var bgc = "#FFFFFF" // background color of the item
var tc = "#FE8201" // text color of the item
  
var over_bgc = "#FFFFFF";
var over_tc = "#007EFE";

if (document.getElementById){ //DynamicDrive.com change
document.write('<style type="text/css">\n')
document.write('.submenu{display: none;}\n')
document.write('</style>\n')
}


function SwitchMenu(obj){
if(document.getElementById){
	var el = document.getElementById(obj);
	var ar = document.getElementById("masterdiv").getElementsByTagName("span"); //DynamicDrive.com change
	if(el.style.display != "block"){ //DynamicDrive.com change
		//for (var i=0; i<ar.length; i++){
		//	if (ar[i].className=="submenu") //DynamicDrive.com change
		//	ar[i].style.display = "none";
		//	}
		el.style.display = "block";
		}else{
		el.style.display = "none";
		}
		}
		}

function color(obj)
{
 document.getElementById(obj).style.backgroundColor = over_bgc;
 document.getElementById(obj).style.color = over_tc;
}

function uncolor(obj)
{
 document.getElementById(obj).style.backgroundColor = bgc;
 document.getElementById(obj).style.color = tc;
}

function startup(id)
{
var icon = "<img src='images/button.jpg' border='0'>"
var first_loop = 0
var item_num = 1
document.write('<div class="menu" id="masterdiv">')

 for(i=0;i<Link.length;i++)
  {
   la = Link[i].split("|");

	if(la[0] == "0")
	{
		if(first_loop == "1")
		{
		document.write('</span>');
		first_loop=0;
		}

		if(la[4] == "0")
			{
   			document.write('<div class="menutitle" id="title' + item_num + '"> ' + icon + ' <a href="'+ la[2] +'">' + la[1] + '</a></div>')
			item_num++
			}
		if(la[4] == "1")
			{
			document.write('<div class="menutitle" id="title' + item_num + '" onmouseover="color(this.id)" onmouseout="uncolor(this.id)" onclick="SwitchMenu(&quot;sub' + item_num + '&quot;)"> ' + icon + ' ' + la[1] + '</div>')
			document.write('<span class="submenu" id="sub' + item_num + '">');
			item_num++
			first_loop=1;
			}
	}   
	else
	{ 	
		document.write('<a href="'+ la[2] +'">' + la[1] + '</a><br>')	;		
	}
  }
 document.write('</div>')

 if(id != '0')
 document.getElementById('sub' + id +'').style.display="block"
}
