// IAAM Menu script

// ------------------------------------------------------------
// menu variable format: link[any number] = "page title|page url" 
// example: link[10] = "Welcome|http://www.iaam.org/meetings/index.htm"
// menu items are displayed in numeric order, add lines as needed, or remark '//' lines not needed
//------------------------------------------------------------

fpath="http://www.iaam.org/Foundation/"
var link = new Array()
link[10] = "Welcome|"+fpath+"foundati.htm"
link[12] = "Foundation<br>Board of Trustees|http://www.iaam.org/Governance/09_10Gov/trustees.htm"
link[15] = "Support for Programs|grants.htm"
link[20] = "Make a Contribution|http://www.iaam.org/Foundation/foundationannualoptions.asp"
link[25] = "Legacy Award|http://www.iaam.org/legacy/index.htm"
link[30] = "Annual Giving Campaign|"+fpath+"2009 Annual Giving Recognition 120909.pdf"
link[35] = "Major Gifts|"+fpath+"major_gifts.htm"
link[40] = "Planned Giving|"+fpath+"plannedgiving.htm"
//link[45] = "Sponsorship|"+fpath+"???.htm"
link[50] = "Foundation Friday<br>Golf Tournament<br>by MillerCoors|http://www.IAAMFoundationGolf.com"
//link[55] = "Foundation Friday Harley Ride|http://www.iaam.org/2008_Conf/golf_foundation.htm"
link[60] = "Silent Auction by Comcast-Spectacor|http://www.iaamfoundation.cmarket.com"
link[65] = "Walkway to Success|"+fpath+"bricks.htm"
//link[70] = "News and Publications|"+fpath+"???.htm"
link[95] = "back to IAAM.org|http://www.iaam.org/"


//------------------------------------------------------------
//DO NOT CHANGE ANYTHING BELOW
//------------------------------------------------------------

function menu(){
  for (x=0;x<100;x++){
    desc = explode(link[x],0,'|');
    url = explode(link[x],1,'|');
    if (url && desc) {
      document.write('<a href="'+url+'">'+desc+'</a><br><img src="../../Design/1PIXEL.GIF" width="143" height="5" border="0"><img src="../../Design/Gray-Navigation-Bar.gif" width="80" height="1" border="0"><br><img src="../../Design/1PIXEL.GIF" width="80" height="5" border="0"><br>');
    }
  }
}

function explode(string,item,delimiter) {
 tempArray=new Array(1);
 var Count=0;
 var tempString=new String(string);
 while (tempString.indexOf(delimiter)>0) {
  tempArray[Count]=tempString.substr(0,tempString.indexOf(delimiter));
  tempString=tempString.substr(tempString.indexOf(delimiter)+1,tempString.length-tempString.indexOf(delimiter)+1);
  Count=Count+1
 }
 tempArray[Count]=tempString;
 return tempArray[item];
}
