fixMozillaZIndex=false; //Fixes Z-Index problem  with Mozilla browsers but causes odd scrolling problem, toggle to see if it helps
var bTestSite=false;
var sHttpPrefix="http://";

// establish test vs live site
if (window.location.toString().toLowerCase().indexOf("minisage.com") > -1)
{
	bTestSite=true;
}
// establish http vs https
if (window.location.toString().toLowerCase().indexOf("https") > -1)
{
	sHttpPrefix = "https://";
}

var nSubMenuAdditionalWidthMedium = 150;   	//mfindlay
var nSubMenuAdditionalWidthWide = 200;    	//mfindlay

var nMenuWidth=200;				// width of menus to appear. Set to zero to ignore
var sBaseSite="";
var sNonSSLBaseSite="";

// If test site, just use 1 base site
if (bTestSite) 
{
	sBaseSite = sHttpPrefix + "fn.minisage.com/";
	sNonSSLBaseSite = "http://" + "fn.minisage.com/";
}
else
{
	sNonSSLBaseSite = "http://" + "www.fundacionpiesdescalzos.com/";
	
	// live site. If https mode, use safesecureweb address
	if (sHttpPrefix=="https://")
	{
		sBaseSite = sHttpPrefix + "www.fundacionpiesdescalzos.com/";  
	}
	else
	{
		// non ssl mode, use normal address
		sBaseSite = sHttpPrefix + "www.fundacionpiesdescalzos.com/";
	}
} 

// set home page identifier, necessary to set the 'left' offset for the flyout between
// the home page and all internal pages
var sHomePage = sBaseSite + "index_es.php";

// Set default locations for flyout menu
var nflyout_top = 7;   // -5
var nflyout_left = -5;  //0




//********************
// TD Top nav onclick
//********************
function NavigateTo(sTarget)
{
	//window.location.href = sBaseSite + sTarget;
	window.location.href = sNonSSLBaseSite + sTarget;
	return true;
}


//var submenuTopOffset = "offset=5";  see iym for reference use in submenu flyouts
//var submenuLeftOffset = "offset=1";

// milonic
_menuCloseDelay=250;           	// The time delay for menus to remain visible on mouse out
_menuOpenDelay=50;             	// The time delay before menus open on mouse over
_subOffsetTop=4;             	// Sub menu top offset from bottom of image associated with it
_subOffsetLeft=5;            	// Sub menu left offset

// MAIN STYLE
with(mainMenuStyle=new mm_style()){
onbgcolor="#bcb294";			// hover background color  // 6E5F3F 
offbgcolor="#bcb294";			// normal (non-hover) background color  #D2B48C
offcolor="#2b2b2b";				// normal (non-hover) text color  
oncolor="#FFFFFF";				// hover text color  
offclass="mmpadding";			// custom style attached to menu
onclass="mmpadding";			// custom style attached to menu
bordercolor="#bcb294";			// border color #B59973
borderstyle="solid";
borderwidth=2;			//1
fontfamily="Arial";				// font / font family
fontsize="11px";				// font size
fontstyle="normal";				// font style   
fontweight="bold";				// font weight (bold)   
//outfilter="Fade(duration=0.1)";
overfilter="Fade(duration=0.1);Alpha(opacity=95);";
//overfilter="Fade(duration=0.1);Alpha(opacity=90);Shadow(color='#777777', Direction=135, Strength=5)";
padding=3;						// menu item cell padding
pagebgcolor="#bcb294"; 			// this is the (non-hover) background color of the menu item last clicked #D2B48C
pagecolor="#FFFFFF";  			// this is the (non-hover) text color of the menu item last clicked 
separatorcolor="#bcb294";		// separator color #D2B48C
separatorsize="1";
subimage=sBaseSite + "graphics/common/flyoutarrow.gif";
subimagepadding="2";
subimageposition="right";
}

//******************** ABOUT US ***********************************
with(milonic=new menuname("mm_aboutus")){
//alwaysvisible=1;
//followscroll=1;
//overflow="scroll";  // Do not use scrollbars on this flyout since it can be so close to bottom of page
style=mainMenuStyle;
itemwidth=200;  
top=nflyout_top;
left=nflyout_left;

//aI("align=center;pointer=move;text=drag to move menu;type=dragable;url=#;");
aI("text=nuestro equipo;url=" + sNonSSLBaseSite + "pages/about/about_staff_es.php;");
aI("text=junta directiva;url=" + sNonSSLBaseSite + "pages/about/about_board_es.php;");
aI("text=nuestra fundadora;url=" + sNonSSLBaseSite + "pages/about/about_founder_es.php;");
aI("text=misi&oacute;n e historia;url=" + sNonSSLBaseSite + "pages/about/about_mission_es.php;");
}
	
//******************** WHAT WE DO ***********************************
with(milonic=new menuname("mm_whatwedo")){
//alwaysvisible=1;
//followscroll=1;
//overflow="scroll";  // Do not use scrollbars on this flyout since it can be so close to bottom of page
style=mainMenuStyle;
itemwidth=200;  
top=nflyout_top;
left=nflyout_left;

//aI("align=center;pointer=move;text=drag to move menu;type=dragable;url=#;");
aI("text=los temas;url=" + sNonSSLBaseSite + "pages/whatwedo/whatwedo_issues_es.php;");
aI("text=programas;url=" + sNonSSLBaseSite + "pages/whatwedo/whatwedo_programs_es.php;");
aI("text=proyectos;url=" + sNonSSLBaseSite + "pages/whatwedo/whatwedo_projects_main_es.php;");
aI("text=historias de &eacute;xito;url=" + sNonSSLBaseSite + "pages/whatwedo/whatwedo_success_stories_es.php;");
aI("text=fotos;url=" + sNonSSLBaseSite + "pages/whatwedo/whatwedo_photos_es.php;");
}
	
//******************** HOW YOU CAN HELP ***********************************
with(milonic=new menuname("mm_howhelp")){
//alwaysvisible=1;
//followscroll=1;
//overflow="scroll";  // Do not use scrollbars on this flyout since it can be so close to bottom of page
style=mainMenuStyle;
itemwidth=200;  
top=nflyout_top;
left=nflyout_left;

//aI("align=center;pointer=move;text=drag to move menu;type=dragable;url=#;");
aI("text=al&iacute;state;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_join_es.php;");
aI("showmenu=HOWHELP_SPONSORACHILD;text=apadrina un ni&ntilde;o;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_sponsor_child_es.php;");
aI("text=donar;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_donate_es.php;");
aI("text=corre la voz;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_spreadword_es.php;");
aI("text=nuestros compa&ntilde;eros;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_corporate_sponsorship_es.php;");
aI("text=ser voluntario;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_volunteer_es.php;");
aI("text=hacer compras;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_shop_es.php;");

}
	with(milonic=new menuname("HOWHELP_SPONSORACHILD")){
	style=mainMenuStyle;
	//itemwidth += nSubMenuAdditionalWidthWide;
	aI("text=ni&ntilde;os apadrinados;url=" + sNonSSLBaseSite + "pages/howhelp/howhelp_sponsored_children_es.php;");
	}
	
//******************** PARTNERSHIPS ***********************************
with(milonic=new menuname("mm_partnerships")){
//alwaysvisible=1;
//followscroll=1;
//overflow="scroll";  // Do not use scrollbars on this flyout since it can be so close to bottom of page
style=mainMenuStyle;
itemwidth=200;  
top=nflyout_top;
left=nflyout_left;

//aI("align=center;pointer=move;text=drag to move menu;type=dragable;url=#;");
aI("text=organizaciones recomendadas;url=" + sNonSSLBaseSite + "pages/partnerships/partnerships_organizations_es.php;");
aI("text=nuestros patrocinadores;url=" + sNonSSLBaseSite + "pages/partnerships/partnerships_sponsors_es.php;");
}

//******************** NEWS ***********************************
//with(milonic=new menuname("mm_news")){
//alwaysvisible=1;
//followscroll=1;
//overflow="scroll";  // Do not use scrollbars on this flyout since it can be so close to bottom of page
//style=mainMenuStyle;
//itemwidth=200;  
//top=nflyout_top;
//left=nflyout_left;

//aI("align=center;pointer=move;text=drag to move menu;type=dragable;url=#;");
//aI("showmenu=NEWS_EVENTS;text=events;url=" + sNonSSLBaseSite + "pages/news/news_events_es.php;");
//aI("text=press releases;url=" + sNonSSLBaseSite + "pages/news/news_press_releases_es.php;");
//}
	//with(milonic=new menuname("NEWS_EVENTS")){
	//style=mainMenuStyle;
	//itemwidth += nSubMenuAdditionalWidthWide;
	//aI("text=email event to a friend;url=" + sNonSSLBaseSite + "pages/news/news_events_email_es.php;");
	//}

//drawMenus();  will do this in main body so we don't lose the page background (milonic bug)

