function MM_findObj(n, d) { //v3.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}


function MM_preloadImages() { //v3.0
 var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
   var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
   if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function fwLoadMenus() {
if (window.fw_menu_0) return;
   window.fw_menu_0 = new Menu("root",200,16,"Verdana, Arial, Helvetica, sans-serif",10,"#FFFFFF","#FFCC66","#4E84C0","#4E84C0");
fw_menu_0.addMenuItem("World Development Indicators","location='http://www.worldbank.org/data/wdi2002/' ");

  fw_menu_0.addMenuItem("Education Outcomes (.pdf) <img src='http://siteresources.worldbank.org/EXTGENDERSTATS/Images/a_acrobat1.gif' width='9' height='9'>","location='eoutcomes.pdf' ");
  fw_menu_0.addMenuItem("Reproductive Health (.pdf) <img src='http://siteresources.worldbank.org/EXTGENDERSTATS/Images/a_acrobat1.gif' width='9' height='9'>","location='rhealth.pdf' ");
  fw_menu_0.addMenuItem("Women in Development (.pdf) <img src='http://siteresources.worldbank.org/EXTGENDERSTATS/Images/a_acrobat1.gif' width='9' height='9'>","location='wdevelopment.pdf' ");
   fw_menu_0.hideOnMouseOut=true;
  //window.fw_menu_1 = new Menu("root1",100,16,"Verdana, Arial, Helvetica, sans-serif",10,"#FFFFFF","#FFFFFF","#4E84C0","#4E84C0");
  //fw_menu_1.addMenuItem("Link1", "location='http://www.adobe.com/' ");
  //fw_menu_1.addMenuItem("Link2", "location='http://www.worldbank.org/data/wdi/home.html' ");
   //fw_menu_1.hideOnMouseOut=true;
  fw_menu_0.writeMenus();
} 

function Is() {
    agent  = navigator.userAgent.toLowerCase();
    this.major = parseInt(navigator.appVersion);
    this.minor = parseFloat(navigator.appVersion);
    this.ns = ((agent.indexOf('mozilla') != -1) && 
	      (agent.indexOf('spoofer') == -1) && (agent.indexOf('compatible') == -1) &&
                    (agent.indexOf('opera') == -1) &&
	      (agent.indexOf('webtv') == -1));	
    this.ns2   = (this.ns && (this.major      ==    3));
    this.ns3   = (this.ns && (this.major      ==    3));
    this.ns4   = (this.ns && (this.major      ==    4));
    this.ns6   = (this.ns && (this.major      >=    5));
    this.ie    = (agent.indexOf("msie")       !=   -1);
    this.ie3   = (this.ie && (this.major      < 4));
    this.ie4   = (this.ie && (this.major      ==    4) && (agent.indexOf("msie 5.0")   ==   -1));
    this.ie5   = (this.ie && (this.major      ==    4) && (agent.indexOf("msie 5.0")   !=   -1));
	this.ieX = (this.ie && !this.ie3 && !this.ie4); 
}

var is = new Is();

function CheckWidth() {
	var available_width;
	var L1;
	
	if(is.ns4 ||is.ns6) {
	    if (innerWidth< 757){	
			available_width=0;
		}
		else{		
			available_width=innerWidth - 756;
		}
	} 
	 else
	{
		if(is.ie4 || is.ie5) 
		{
	      		if (document.body.clientWidth< 740)
			{	
			available_width=0;
			}
			else
			{		
			available_width=document.body.clientWidth - 740;
			} 
		}
	}
	L1=available_width/2+450;
	// alert("L1-"+L1);
	//document.write ("<a href='home.asp' onMouseOut='MM_swapImgRestore(),FW_startTimeout();'  onMouseOver='window.FW_showMenu(window.fw_menu_0,"+L1+",142);'>");
	document.write ("<a onMouseOut='MM_swapImgRestore(),FW_startTimeout();'  onMouseOver='window.FW_showMenu(window.fw_menu_0,"+L1+",142);'>");
	return;
}

function CheckWidth2() {
	var available_width2;
	var L2;
	
	if(is.ns4 ||is.ns6) {
	    if (innerWidth< 757){	
			available_width2=0;
		}
		else{		
			available_width2=innerWidth - 756;
		}
	 } 
	 else
	 {
		if(is.ie4 || is.ie5) 
		{
	      		if (document.body.clientWidth< 740)
			{	
			available_width2=0;
			}
			else
			{		
			available_width2=document.body.clientWidth - 740;
			} 
		}
	}
	L2=available_width2/2+638;
	// alert("L2-"+L2);
	document.write ("<a href='home.htm' onMouseOut='MM_swapImgRestore(),FW_startTimeout();'  onMouseOver='window.FW_showMenu(window.fw_menu_1,"+L2+",142);'>");
	return;
}