/*
 Milonic DHTML Menu 3.x - with alterations
 
 TO OPEN MENU ITEM IN NEW WINDOW:
 (1) Begin link with "http" and the item
     will open in a new window.  Else, use
	 /foldername/filename.ext
  -  See menu.js lines 350 ff. for code.
  
  // NEW WINDOW CAUSES PROBLEMS FOR SOME NETSCAPE
  // SO IS DISCONTINUED ... but I think I know why
  // Netscape didn't like the code, and I left notes
  // in menu.js as to how I believe we can open new
  // windows without any further problems.
  // lb 12/15/2005
*/

menunum=0;menus=new Array();_d=document;
function addmenu(){menunum++;
menus[menunum]=menu;
}
// Fade, opacity, dropshadow
effect = "Fade(duration=0.2);Alpha(style=0,opacity=95);Shadow(color='#777777', Direction=135, Strength=5)"

// HEIGHT for top of menu
var strHref = window.location.href
if ( strHref == "http://apsnetdev/" || strHref=="http://172.16.1.61/")
{
	var topHeight = "142" // top page start height 142
}
else if ( strHref == "http://apsnetdev/top.asp")
{
	var topHeight = "142" // top page start height
}
else if ( strHref == "http://www.apsnet.org/")
{
	var topHeight = "142" // top page start height
}
else if ( strHref == "http://www.apsnet.org/top.asp")
{
	var topHeight = "142" // top page start height
}
else
{
	var topHeight = "93" // sub page
}

// COLORS: This menu has a variety of color schemas

var FirstFold = strHref.split("/")
if ( FirstFold[3] == "education")
{
	var strBgColor = "FFFFFF" // ed center 
	var strRollOver = "D8F1FD"
	var strDivider = "5FB5E0"
	var strRollFont = "000000"
	var strBorder = "FFFFFF"
	var topHeight = "94" // lower one pixel
	var imgLogo = "apsLogo2_100_ED.gif" // logo w blue line
}
else if ( FirstFold[3] == "mpmi")
{
	var strBgColor = "CCCC99" // mpmi  /mpmi/top.asp
	var strRollOver = "996600"
	var strDivider = "996600"
	var strRollFont = "FFFFCC"
	var strBorder = "CCCC99"
	var topHeight = "89" // raise menu a few pixels
	var imgLogo = "apsLogo2_100_MPMI.gif" // olive drab logo
}
else if ( FirstFold[3] == "pd") // pd  /pd/top.asp
{
	var strBgColor = "FFFFCC" 
	var strRollOver = "B19B45"
	var strDivider = "cccc98"
	var strRollFont = "FFFFCC"
	var strBorder = "FFFFFF"
	var topHeight = "90" // raise menu a few pixels
}
else if ( FirstFold[3] == "phyto") // phtyo  /phyto/top.asp
{
	var strBgColor = "FFFFCC" 
	var strRollOver = "B19B45"
	var strDivider = "cccc98"
	var strRollFont = "FFFFCC"
	var strBorder = "FFFFFF"
	var topHeight = "89" // raise menu a few pixels
}
else if ( FirstFold[4] == "ppb2") //  /members/ppb2/
{
	var strBgColor = "FFFFFF" 
	var strRollOver = "D8F1FD"
	var strDivider = "5FB5E0"
	var strRollFont = "000000"
	var strBorder = "FFFFFF"
	var topHeight = "100" // lower one pixel
}
else if ( FirstFold[4] == "centennial") //  /members/centennial/
{
	var strBgColor = "FFFFFF" 
	var strRollOver = "EBEBEB"
	var strDivider = "ABABAB"
	var strRollFont = "000000"
	var strBorder = "FFFFFF"
	var topHeight = "92" // lower one pixel
}
else
{
	var strBgColor = "FFFFCC" // normal
	var strRollOver = "B19B45"
	var strDivider = "cccc98"
	var strRollFont = "FFFFCC"
	var strBorder = "FFFFFF"
}

// mac running ie starts x y in cell, not top right of page
var version = navigator.appVersion;
if ((navigator.userAgent.indexOf("MSIE")!=-1) && (version.toLowerCase().indexOf("mac")!=-1))
{
var topHeight = "2"
}
else
{
// nothing
}

function dumpmenus() // all at once
// a is integer
{mt="<script language=javascript>";
	// start loop
	for(a=1;a<menus.length;a++)
	{
	mt+=" menu"+a+"=menus["+a+"];"
	}
	// end loop
	mt+="<\/script>";
	_d.write(mt);
	// Display logo at bottom of menu
	//_d.write("<img width='1' height='289' src='/images/spacer.gif'><br><a href='/'><img border='0' src='/images/"+imgLogo+"'></a>");
	}

timegap=100			// The time delay for menus to remain visible ' 500 orig
followspeed=100		// Follow Scrolling speed '5 orig
followrate=40		// Follow Scrolling Rate '40 orig
suboffset_top=0;	// Sub menu offset Top position
suboffset_left=10;	// Sub menu offset Left position
closeOnClick = true

style1=[			// style1 is an array of properties. You can have as many property arrays as you need. This means that menus can have their own style.
"000000",			// Mouse Off Font Color 'VERYdarkGreen(003300)
strBgColor,			// Mouse Off Background Color ' lightYellow(FFFFCC) or green(669966)
strRollFont,		// Mouse On Font Color
strRollOver,		// Mouse On Background Color ' weirdYellow(C49217) or green(669966)
strBorder,			// BELOW - Set Border Size below if want this to appear
10,					// Font Size in pixels
"normal",			// Font Style (italic or normal)
"normal",			// Font Weight (bold or normal)
"Verdana, Arial",	// Font Name
3,					// Menu Item Padding
,					// Sub Menu Image (Leave this blank if not needed)
,					// 3D Border & Separator bar
"",					// 3D High Color
"",					// 3D Low Color
"000000",			// Current Page Item Font Color (leave this blank to disable)
"cccc98",			// Current Page Item Background Color (leave this blank to disable)
,					// Top Bar image (Leave this blank to disable)
,					// Menu Header Font Color (Leave blank if headers are not needed)
"000000",			// Menu Header Background Color (Leave blank if headers are not needed)
strDivider,			// Menu Item Separator Color ' gray(C8C8C6), gold(C49217) or green(669966)
]

addmenu(menu=[		// This is the array that contains your menu properties and details
"mainmenu",			// Menu Name - This is needed in order for the menu to be called
topHeight,			// Menu Top - The Top position of the menu in pixels
1,					// Menu Left - The Left position of the menu in pixels (deleted value - lb)
160,				// Menu Width - Main item width in pixels 
1,					// Menu Border Width (blank now, can add val- lb)
"Left",				// Screen Position - here you can use "center;left;right;middle;top;bottom" or a combination of "center:middle"
style1,				// Properties Array - this is set higher up, as above
1,					// Always Visible - allows the menu item to be visible at all time (1=on/0=off)
"left",				// Alignment - sets the menu elements text alignment, values valid here are: left, right or center
"center",			// Filter - Text variable for setting transitional effects on menu activation - see above for more info
,					// Follow Scrolling - Tells the menu item to follow the user down the screen (visible at all times) (1=on/0=off)
0, 					// Horizontal Menu - Tells the menu to become horizontal instead of top to bottom style (1=on/0=off)
,					// Keep Alive - Keeps the menu visible until the user moves over another menu or clicks elsewhere on the page (1=on/0=off)
,					// Position of TOP sub image left:center:right
,					// Set the Overall Width of Horizontal Menu to 100% and height to the specified amount (Leave blank to disable)
,					// Right To Left - Used in Hebrew for example. (1=on/0=off)
,					// Open the Menus OnClick - leave blank for OnMouseover (1=on/0=off)
,					// ID of the div you want to hide on MouseOver (useful for hiding form elements)
,					// Background image for menu when BGColor set to transparent.
,					// Scrollable Menu
,					// Reserved for future use

// "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"

,"ABOUT APS","show-menu=visitors","#","About APS",1
,"JOURNALS & NEWS","show-menu=journals","#","APS Journals and News",1
,"APS MEMBER AREA","show-menu=members","#","APS Members Area",1
,"CAREERS & PLACEMENT","show-menu=careers","#","Careers in Plant Pathology",1
,"EDUCATION CENTER","show-menu=edcenter","#","APSnet Education Center",1
,"ONLINE RESOURCES","show-menu=online","#","APS Online Resources",1
,"CENTENNIAL CELEBRATION","/centennial/","#","APS Centennial Celebration",1
,"CALENDAR","show-menu=calendar","#","Meetings and Events Calendar",1
,"MEETINGS","show-menu=meetings","#","APS Meetings",1
,"MEDIA/OUTREACH CENTER","show-menu=media","#","Media and Public Affairs Area",1
,"APS PRESS","show-menu=apspress","#","APS Press",1
,"APS FOUNDATION","show-menu=foundation","#","APS Foundation",1
,"MEMBER DIRECTORY","show-menu=memdirectory","#","APS Membership Directory",1
,"DIRECTORIES & ROSTERS","show-menu=directories","#","APS Directories and Rosters",1
,"APS INTERACTIVE","show-menu=interactive","#","APS Interactive - Communities, Events",1
,"JOIN APS!","show-menu=join","#","Join the American Phytopathological Society",1
,"CONTACT APSnet","show-menu=contact","#","Contact APSnet",1
])

	addmenu(menu=["visitors",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"APS Overview","/visitors/about.asp",,,1
	,"What is Phytopathology?","/visitors/phytinfo.asp",,,1
	,"Membership","/visitors/membership.asp",,,1
	,"Search APSnet","/visitors/search.aspx",,,1
	])
	
	addmenu(menu=["media",
	,,180,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Media Kit","/media/mediakit.asp",,,1
	,"Why Plant Pathology is Newsworthy","/media/",,,1
	,"Hot Topics/Recent Research","/media/hottopics.asp",,,1
	,"News Releases","/media/press/",,,1
	,"Members in the News","/media/membersinthenews.asp",,,1
	,"Media Mentions","/media/mediamentions.asp",,,1
	,"Journalism Award","/media/PlantPathologyJournalismAward.asp",,,1
	,"Media Events","/media/upcoming.asp",,,1
	,"News Release Sign-Up","/media/press/mailform.asp",,,1
	,"Public Policy Initiatives","/members/ppb/",,,1
	,"Contacts","/media/contact.asp",,,1
	])

	addmenu(menu=["edcenter",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Main Menu","/education/top.html",,,1
	,"Search the Ed Center","/education/search/search.aspx",,,1
	])

	addmenu(menu=["careers",
	,,210,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Overview","/careers/",,,1
	,"Find a Job","/careers/jobfind.asp",,,1
	,"Post a Resume/Vita","/careers/vitapost.asp",,,1
	,"Post a Job","/careers/jobpost.asp",,,1
	,"Find an Employee","/careers/vitafind.asp",,,1
	,"Careers in Plant Pathology","#",,,1
	,"&nbsp; - What is a Plant Pathologist?","/careers/careers.asp",,,1
	,"&nbsp; - Career Brochure","/careers/careerbrochure.asp",,,1
	,"&nbsp; - Career Paths Workshop","/careers/careerpath.asp",,,1
	,"Advice, Tips, Guidelines","/careers/joblinks.asp",,,1
	])

	addmenu(menu=["journals",
	,,210,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"APS Journals Home Page","http://apsjournals.apsnet.org/",,,1
	,"Search APS Journals","http://apsjournals.apsnet.org/search/advanced",,,1
	,"Phytopathology","http://apsjournals.apsnet.org/loi/phyto",,,1
	,"Plant Disease","http://apsjournals.apsnet.org/loi/pdis",,,1
	,"MPMI","http://apsjournals.apsnet.org/loi/mpmi",,,1
	,"Phytopathology News","/members/phyto/",,,1
	,"Plant Health Instructor","/education/",,,1
	,"Plant Management Network","http://www.plantmanagementnetwork.org/",,,1
	,"&nbsp; - Plant Health Progress","http://www.plantmanagementnetwork.org/php/",,,1
	,"&nbsp; - PDMR","http://www.plantmanagementnetwork.org/pub/trial/pdmr/",,,1
	,"Subscription Information","/journals/",,,1
	,"Advertise in APS Publications","/journals/advertising/",,,1
	])

	addmenu(menu=["calendar",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Event Calendar","/meetings/calendar/",,,1
	,"Submit a Calendar Item","/meetings/calendar/addevent.aspx",,,1
	])
	
	addmenu(menu=["online",
	,,250,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Overview","/online/",,,1
	,"Webcasts","/webcasts/",,,1
	,"Common Names of Plant Diseases","/online/common/",,,1
	,"APSnet Features","/online/feature/",,,1
	,"PDMR Author Guidelines","/online/pdmr/guidelines",,,1
	,"Plant Disease Management Reports","http://www.plantmanagementnetwork.org/pub/trial/pdmr/",,,1
	,"B&C Tests","http://www.plantmanagementnetwork.org/pub/trial/pdmr/",,,1
	,"F&N Tests","http://www.plantmanagementnetwork.org/pub/trial/pdmr/",,,1
	,"Image Resources","/online/image.asp",,,1
	,"Proceedings of:","#",,,1
	,"&nbsp; - Nat'l Soybean Rust Symposium 2007","http://www.plantmanagementnetwork.org/infocenter/topic/soybeanrust/2007/",,,1
	,"&nbsp; - Nat'l Soybean Rust Symposium 2006","http://www.plantmanagementnetwork.org/infocenter/topic/soybeanrust/2006/",,,1
	,"&nbsp; - Nat'l Soybean Rust Symposium 2005","http://www.plantmanagementnetwork.org/infocenter/topic/soybeanrust/symposium/",,,1
	,"&nbsp; - Sudden Oak Death Symposium","/online/proceedings/SOD/",,,1
	,"&nbsp; - Exotic Forest Pests Workshop","/online/proceedings/ExoticPest/index.html",,,1
	,"&nbsp; - Int'l Karnal Bunt Discussion","/online/proceedings/karnal/top.html",,,1
	,"&nbsp; - Potato Late Blight Workshop","/online/proceedings/lateblite/",,,1
	,"&nbsp; - Detecting Microbes in Soil","/online/proceedings/SoilMicrobes/",,,1
	,"&nbsp; - Future of Education in Plant Pathology","/online/proceedings/Education_Workshop/",,,1
	
	])

	addmenu(menu=["meetings",
	,,180,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Annual Meeting 2010","http://meeting.apsnet.org/default.cfm",,,1
	,"Annual Meeting Archives","/meetings/abstracts.asp",,,1
	,"Future Meeting Sites","/meetings/annual/future.asp",,,1
	,"Division Meetings","/meetings/div/",,,1
	,"Nat'l Plant Diagnostic Network 2009","/meetings/NPDN/",,,1
	,"Nat'l Soybean Rust Symposium 2009","/online/sbr/",,,1
	,"Meeting Planning Materials","/meetings/planning/",,,1
	,"Online Event Proposal Form","/meetings/online/",,,1
	])
	
	addmenu(menu=["apspress",
	,,160,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Shop the Bookstore","http://www.shopapspress.org/",,,1
	,"Publish with APS Press","/press/",,,1
	,"Author/Editor Instructions","/press/instructions.asp",,,1
	,"Editorial Board","/members/com/boards_detail.cfm?Code=EDAPRESS",,,1
	])
	
	addmenu(menu=["members",
	,,180,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"What's New","/members/",,,1
	,"Member Services","/members/member.asp",,,1
	,"Renew Your Membership","/members/renew.asp",,,1
	,"Frequently Asked Questions","/members/faq.asp",,,1
	,"Awards","/members/awards/",,,1
	,"Council/Governance","/members/gov/",,,1
	,"Boards & Offices","/members/boards.asp",,,1
	,"Divisions","/members/div/",,,1
	,"Committees","/members/com/",,,1
	,"Phytopathology News","/members/phyto/",,,1				
	,"Vision of Plant Pathology","/members/vision/",,,1
	])
	
	addmenu(menu=["foundation",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Mission","/foundation/",,,1
	,"Donate","/foundation/donationform.asp",,,1
	,"Giving Options","/foundation/future.asp",,,1
	,"Foundation Funds","/foundation/special.asp",,,1
	,"Apply for Funding","/foundation/ApplyFunding.asp",,,1
	,"Awardees","/foundation/awardees.asp",,,1
	,"Contributors","/foundation/donors.asp",,,1
	,"News","/foundation/news.asp",,,1
	,"Contact","/members/com/boards_detail.cfm?Code=APSFDN",,,1			
	])
	
	addmenu(menu=["memdirectory",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Speed Search","http://interactive.apsnet.org/source/Members/ssmemsearch.cfm",,,1
	,"Advanced Search","http://interactive.apsnet.org/source/Members/ssAdvDirSearch.cfm",,,1
	])
	
	addmenu(menu=["directories",
	,,210,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Membership Directory","http://interactive.apsnet.org/source/members/memberhome.cfm?section=unknown&activesection=customer",,,1
	,"Headquarters Staff","/directories/staff.asp",,,1
	,"Committee Members","/members/com/top.asp",,,1
	,"Council","/directories/council.cfm",,,1
	,"Sustaining Associates","/directories/sustain.cfm",,,1
	,"Extension Specialists","/directories/extension/top.asp",,,1
	,"Private Practitioners","http://interactive.apsnet.org/source/Members/default.cfm",,,1
	,"University Programs","/directories/uprogs.asp",,,1
	,"University Dept. Heads","/directories/depthead.cfm",,,1	
	,"University Diagnosticians","/directories/univ_diagnosticians.asp",,,1	
	,"ISPP World Directory","http://www.isppweb.org/about_world_directory.asp",,,1
	,"Affiliated Organizations","/directories/affiliated_organizations.cfm",,,1
	,"Plant Pathology Internet Guidebook","http://www.pk.uni-bonn.de/ppigb/ppigb.htm",,,1
	])

	addmenu(menu=["interactive",
	,,150,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Interactive Home","http://interactive.apsnet.org/scriptcontent/index.cfm",,,1
	,"Event Registration","http://interactive.apsnet.org/source/meetings/meetingshome.cfm?section=events",,,1
	,"Communities","http://interactive.apsnet.org/source/communities/userhomepage.cfm?section=communities",,,1
	])
	
	addmenu(menu=["join",
	,,170,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Benefits","/visitors/mbrinfo.asp",,,1
	,"Testimonials","/visitors/testimonials.asp",,,1
	,"Application","https://interactive.apsnet.org/source/members/ssMemberSignup.cfm?pcode=2010",,,1
	,"Request Info","/visitors/request.asp",,,1
	,"Sign Up: Free Membership","/visitors/drawing.asp",,,1
	,"Renew Your Membership","/members/renew.asp",,,1
	])
	
	addmenu(menu=["contact",
	,,170,1,"",style1,,"left",effect,,,,,,,,,,,,
	,"Send Your Comments","/members/webadmin.asp",,,1
	,"Change of Address Form","/members/update.asp",,,1
	,"Update Demographic Info","/members/demsurvey.asp",,,1
	,"Headquarters Contacts","/directories/staff.asp",,,1
	])

dumpmenus()
