var USER = new getUserInfo();
countryList = [["cn","kr","in","tw","au","ea","pk","hk","nz","jp"], ["de","fr","es","ru","uk","it","nl","pl","ro","tr","cz","il","me","hu","se","dk","ch-de","fi","za","no","be","pt","at","ie","sk","hr","si","gr","bg","ao","ee","ba","ch-fr","eu","lt","lv","yu","cy","mt"], ["lad","br"],["ca-en","ca-fr"]];
regionList = ["APAC","EMEA","LAD","North America"];

function getUserInfo() {
  var USER         = new Object();
  this.value_enc   = getCookieData("ORA_UCM_INFO");
  this.array       = this.value_enc.split("~");
  USER.version      = this.array[0];
  USER.guid         = this.array[1];
  USER.firstname    = this.array[2];
  USER.lastname     = this.array[3];
  USER.username     = this.array[4];
  USER.country      = this.array[5];
  USER.language     = this.array[6];
  USER.interest1    = this.array[7];
  USER.interest2    = this.array[8];
  USER.interest3    = this.array[9];
  USER.interest4    = this.array[10];
  USER.ascii        = this.array[11];	
  USER.email        = this.username;
  USER.companyname  = null;
  USER.title        = null;
  USER.characterset = null;
  USER.interest5    = null;
  return USER;
}


function sso_sign_out() 
{ 
    //rUrl = window.location.href; 
    
    rUrl = escape(window.location.href); 
		
	if (    ( rUrl.indexOf('http://oraclepartnernetwork.oracle.com/portal/' ) >-1 )  ||  (  rUrl.indexOf('http://www.oracle.com/partners' ) > -1 )  )  		
	  rUrl = "http://oraclepartnernetwork.oracle.com/";
	window.location="http://profile.oracle.com/jsp/reg/signout.jsp?logouturl="+rUrl; //stage only
} 

function printWelcome()
{
  var loc= window.location.href;
  var tempURL= window.location.href;

  var temp = new Array();
  temp = tempURL.split('/');

  var tmp = '<span class="profile">';
  if ( USER.guid ){
	 if(temp[4] == "jp" ){
		 tmp += '<style type="text/css">.profile {margin:0 2px 0 0; display:inline; font-family:"lr oSVbN", Osaka, sans-serif;font-size:10px;}</style>';
	 	 tmp += '<script type="text/javascript">disp_customer();</script>';
	 }
	else if(temp[3] == "global" || temp[3] == "lang"){
		tmp += strings.ident_label + ' ( <a class="profile" href="javascript:sso_sign_out();">' +
			  strings.signout_label + '</a> | <a class="profile" href="http://www.oracle.com/admin/account/index.html?code='+temp[4]+ '">' + strings.account_label + '</a> )';
	 }
	 else {
		tmp += 'Welcome ' + USER.firstname + ' ( <a class="profile" href="http://www.oracle.com/admin/account/index.html">' + 'Account' + '<\/a> | <a class="profile" href="http://www.oracle.com/admin/account/index.html">' + 'Manage Subscriptions' + '<\/a> | <a class="profile" href="javascript:sso_sign_out();">' +'Sign Out'+ '<\/a>)';
	 }	
  }else{
	  if(temp[4] == "jp" ){
		 tmp += '<style type="text/css">.profile {margin:0 2px 0 0; display:inline; font-family:"lr oSVbN", Osaka, sans-serif;font-size:10px;}</style>';
	 	 tmp += '<script type="text/javascript">disp_customer();</script>';
	 }
     else if(temp[3] == "global" || temp[3] == "lang"){
    	tmp += '<a href="' + strings.signin_URL + '">' + '(' + strings.signin_label + '<\/a>' + ' <span style="color:#000000">|</span> ' + '<a href="' + 'http://www.oracle.com/subscribe/index.html' + '">' + strings.subscribe_label + ')' + '<\/a>';
  	 }else{
    	tmp += '<a href="' + 'http://www.oracle.com/admin/account/index.html">' + '(Sign In/Register for Account' + '<\/a>' + ' <span style="color:#000000">|</span> ' + '<a href="' + 'http://www.oracle.com/subscribe/index.html">' + 'Subscribe)' + '<\/a>';
	 }	
  }
  tmp += '</span>';
  sitecatalyst_country = temp[4];
	
	for(i=0;i<countryList.length;i++)
	{
		for(j=0;j<countryList[i].length;j++)
		{
			if(countryList[i][j]==sitecatalyst_country)
			{
				sitecatalyst_region = regionList[i];
			}
		}
	}
	
  document.write(tmp);
  document.close();
}

function signout(url)
{

  //rUrl = window.location.href; 
  rUrl = escape(window.location.href); 
  window.location="http://profile.oracle.com/jsp/reg/signout.jsp?logouturl="+rUrl; //stage only
}


function getCookieData(label) {
  var labelLen = label.length
  var cLen = document.cookie.length
  var i = 0
  var cEnd
  while (i < cLen) {
    var j=i+labelLen;
    if (document.cookie.substring(i,j) == label) {
      cEnd=document.cookie.indexOf(";",j);
      if (cEnd==-1) {
      	cEnd=document.cookie.length;
      }
      j++;
      return decodeURIComponent(document.cookie.substring(j,cEnd));
    }
    i++;
  }
  return "";
}



  function findPosX(obj)
  {
    var curleft = 0;
    if(obj.offsetParent)
        while(1) 
        {
          curleft += obj.offsetLeft;
          if(!obj.offsetParent)
            break;
          obj = obj.offsetParent;
        }
    else if(obj.x)
        curleft += obj.x;
    return curleft;
  }
  
  function findPosY(obj)
  {
    var curtop = 0;
    if(obj.offsetParent)
        while(1)
        {
          curtop += obj.offsetTop;
          if(!obj.offsetParent)
            break;
          obj = obj.offsetParent;
        }
    else if(obj.y)
        curtop += obj.y;
    return curtop;
  }
// Worldwide popup menu
function panelMOv() {
	if (navigator.appName != "Netscape") {
		var dropdown = document.getElementById("group");
		dropdown.style.visibility = "hidden";
	}
	var p = document.getElementById("panelDiv");
	p.style.visibility = "visible";
}

function panelMOu() {
	var p = document.getElementById("panelDiv");
	p.style.visibility = "hidden";
	
	if (navigator.appName != "Netscape") {
		var dropdown = document.getElementById("group");
		dropdown.style.visibility = "visible";
	}
}

function mvqMOv() {

	if (navigator.appName != "Netscape") {
		var dropdown = document.getElementById("group");
		dropdown.style.visibility = "hidden";
	}
	
	var mvqPDiv = document.getElementById("panelDiv"); 
	mvqPDiv.style.visibility = "visible";

}

function mvqMOu() {
	var mvqPDiv = document.getElementById("panelDiv"); 
	mvqPDiv.style.visibility = "hidden";

	if (navigator.appName != "Netscape") {
		var dropdown = document.getElementById("group");
		dropdown.style.visibility = "visible";
	}
}
	
//more industries
function indMOv() {
	var indarrow = document.getElementById("indarrow"); 
	var x = findPosX(indarrow);
	var y = findPosY(indarrow);

	var indDiv = document.getElementById("indDiv"); 
	//alert(navigator.appName);
	//if (navigator.appName == "Netscape")
		x = x-26;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu() {
	var indDiv = document.getElementById("indDiv"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement)) {
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else {
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
		}
}

function indPanelMOv() {
	var indDiv = document.getElementById("indDiv"); 
	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indPanelMOu() {
	var indDiv = document.getElementById("indDiv"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement)){
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
			}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
		}
}

//Database
function indMOv2() {
	var indDiv = document.getElementById("indDiv2"); 
  indDiv.style.visibility = "visible";
}

function indMOv2() {
	var indarrow2 = document.getElementById("indarrow2"); 
	var x = findPosX(indarrow2);
	var y = findPosY(indarrow2);

	var indDiv = document.getElementById("indDiv2"); 
	//alert(navigator.appName);
//if (navigator.appName == "Netscape")
		x = x-26;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu2() {
	var indDiv = document.getElementById("indDiv2"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

function indPanelMOv2() {
	var indDiv = document.getElementById("indDiv2"); 
	indDiv.style.visibility = "visible";
}

function indPanelMOu2() {
	var indDiv = document.getElementById("indDiv2"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}
//Middleware
function indMOv3() {
	var indDiv = document.getElementById("indDiv3"); 
  indDiv.style.visibility = "visible";
}

function indMOv3() {
	var indarrow3 = document.getElementById("indarrow3"); 
	var x = findPosX(indarrow3);
	var y = findPosY(indarrow3);

	var indDiv = document.getElementById("indDiv3"); 
	//alert(navigator.appName);
//if (navigator.appName == "Netscape")
		x = x-26;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu3() {
	var indDiv = document.getElementById("indDiv3"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

function indPanelMOv3() {
	var indDiv = document.getElementById("indDiv3"); 
	indDiv.style.visibility = "visible";
}

function indPanelMOu3() {
	var indDiv = document.getElementById("indDiv3"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}
//Business Solutions
function indMOv1() {
	var indDiv = document.getElementById("indDiv1"); 
  indDiv.style.visibility = "visible";
}

function indMOv1() {
	var indarrow1 = document.getElementById("indarrow1"); 
	var x = findPosX(indarrow1);
	var y = findPosY(indarrow1);

	var indDiv = document.getElementById("indDiv1"); 
	//alert(navigator.appName);
//if (navigator.appName == "Netscape")
		x = x-26;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu1() {
	var indDiv = document.getElementById("indDiv1"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

function indPanelMOv1() {
	var indDiv = document.getElementById("indDiv1"); 
	indDiv.style.visibility = "visible";
}

function indPanelMOu1() {
	var indDiv = document.getElementById("indDiv1"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}
//New addional code for Oracle Listens Starts here
//News and Events
function indMOv4() {
	var indDiv = document.getElementById("indDiv4"); 
  indDiv.style.visibility = "visible";
}

function indMOv4() {
	var indarrow4 = document.getElementById("indarrow4"); 
	var x = findPosX(indarrow4);
	var y = findPosY(indarrow4);

	var indDiv = document.getElementById("indDiv4"); 
	//alert(navigator.appName);
//if (navigator.appName == "Netscape")
		x = x-200;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu4() {
	var indDiv = document.getElementById("indDiv4"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

function indPanelMOv4() {
	var indDiv = document.getElementById("indDiv4"); 
	indDiv.style.visibility = "visible";
}

function indPanelMOu4() {
	var indDiv = document.getElementById("indDiv4"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

//Resources
function indMOv5() {
	var indDiv = document.getElementById("indDiv5"); 
  indDiv.style.visibility = "visible";
}

function indMOv5() {
	var indarrow5 = document.getElementById("indarrow5"); 
	var x = findPosX(indarrow5);
	var y = findPosY(indarrow5);

	var indDiv = document.getElementById("indDiv5"); 
	//alert(navigator.appName);
//if (navigator.appName == "Netscape")
		x = x-200;
	//else
		//x = x-26;
	if (navigator.appName == "Netscape")
		y = y+14;
	else
		y = y+12;
	//alert(x + " " + y);
	indDiv.style.left=x+'px';
	indDiv.style.top=y+'px';
	indDiv.style.position="absolute";
	
  	indDiv.style.visibility = "visible";
	indDiv.style.display = "";
}

function indMOu5() {
	var indDiv = document.getElementById("indDiv5"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

function indPanelMOv5() {
	var indDiv = document.getElementById("indDiv5"); 
	indDiv.style.visibility = "visible";
}

function indPanelMOu5() {
	var indDiv = document.getElementById("indDiv5"); 
	if (navigator.appName != "Netscape") {
		if (!indDiv.contains(window.event.toElement))
		{
			indDiv.style.visibility = "hidden";
			indDiv.style.display = "";
		}
	} else
	{
		indDiv.style.visibility = "hidden";
		indDiv.style.display = "";
	}
}

   
//New addional code for Oracle Listens Ends here

// Function for the worldwide popup
function worldwideCountries(){
document.writeln("<div id=\'panelDiv\' style=\"position:absolute;right:10;visibility:hidden; z-index:1000; WIDTH: 620px; BORDER-RIGHT: #9b9b9b 2px solid; PADDING-RIGHT: 12px;BORDER-TOP: #9b9b9b 2px solid; PADDING-LEFT: 12px; PADDING-BOTTOM: 12px; BORDER-LEFT: #9b9b9b 2px solid; PADDING-TOP: 12px;BORDER-BOTTOM: #9b9b9b 2px solid; BACKGROUND-COLOR: #f8f7f7\" onmouseover=\"panelMOv();\" onmouseout=\"panelMOu();\">");
document.writeln("<table width=100%>");
document.writeln("<tr align=left><td colspan=5 class=\'sngPst\' style=\"border-bottom:#cccccc 1px solid\"><b>SELECT A SECTION OF AIBS WEBSITE TO VIEW<\/b><\/td><\/tr>");
document.writeln("<tr valign=top><td width=20% class=\'sngPst\'>");
document.writeln("<div nowrap><a href=\"index.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:Home Page\';\">Home Page<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"about.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:ARGENTINA\';\">About AIBS<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"msn.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:AUSTRIA\';\">Our Mission<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"ini.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BAHRAIN\';\">AIBS Initiatives<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"pat.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BANGLADESH\';\">Patrons<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"vpat.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BELGIUM AND LUXEMBOURG\';\">Vice Patrons<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"mgt.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BELIZE\';\">Management<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"bd.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BHUTAN\';\">Board Of Directors<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"gc.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BOLIVIA\';\">Governing Council<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"comm.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BOLIVIA\';\">Committees<\/a><\/div> ");
document.writeln("<div nowrap>===================<\/div> ");
document.writeln("<div nowrap><a href=\"mem_ben.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BRASIL\';\">Membership Benefits<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"mem_cat.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BRUNEI\';\">Membership Categories<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"register.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:BULGARIA\';\">Join Us<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"reg_form.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CAMBODIA\';\">Individual Membership Form<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"corp_form.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CANADA - ENGLISH\';\">Corporate Membership Application Form<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"mem_ren.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CANADA - ENGLISH\';\">Renew Your Membership<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"mem_pol.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CANADA - ENGLISH\';\">Membership Policy<\/a><\/div> ");
document.writeln("<\/td>");
document.writeln("<td width=20% class=\'sngPst\'>");
document.writeln("<div nowrap><a href=\"chp.php#spon\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CROATIA\';\">Become a Chapter Sponsor<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"chp.php#pat\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CYPRUS\';\">Chapter Patron<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"chp.php#csc\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:CZECH REPUBLIC\';\">CSC Information<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"chp.php#africa\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:DENMARK\';\">Country Chapters<\/a><\/div> ");
document.writeln("<div nowrap>====================<\/div> ");
document.writeln("<div nowrap><a href=\"cert_ben.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:EGYPT\';\">Certification Benefits<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"cert_pro.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:ESTONIA\';\">Process<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"stud_form.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:EUROPEAN UNION\';\">Student Registration Form<\/a><\/div>");
document.writeln("<div nowrap><a href=\"faq.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:FINLAND\';\">FAQs<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"cert_mem.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:FRANCE\';\">Certified AIBS Members<\/a><\/div> ");
document.writeln("<div nowrap>=============================<\/div> ");
document.writeln("<div nowrap><a href=\"/global/gr/index.html\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:GREECE\';\">AIBS Certification Programs<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"courses.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:GAUTEMALA\';\">Courses<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"cp.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:HONDURAS\';\">Become a Certified Trainer<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"cspbst.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:HONGKONG\';\">CBST<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"webinars.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:HUNGARY\';\">Webinars<\/a><\/div> ");

document.writeln("<\/td>");
document.writeln("<td width=20% class=\'sngPst\'>");

document.writeln("<div nowrap><a href=\"bq.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:IRELAND\';\">Become a CBST<\/a><\/div>");
document.writeln("<div nowrap><a href=\"http://www.irisjobstation.com\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:ISRAEL\';\">Job Board<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"http://www.irisjobstation.com\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:ITALY';\">Post A Job<\/a><\/div> ");
document.writeln("<div nowrap>========================<\/div> ");
document.writeln("<div nowrap><a href=\"news.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:KAZAKHSTAN\';\">News & Events Page<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"press.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:KOREA\';\">Press Release<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"newsletter.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:LAOS\';\">Member Newsletter<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"ec.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:LATVIA\';\">Events Calendar<\/a><\/div> ");
document.writeln("<div nowrap>===========================<\/div> ");
document.writeln("<div nowrap><a href=\"bec_part.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:LITHUANIA\';\">Partner Opportunities<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"aso.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALAYSIA\';\">Sponsorship Opportunities<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"partners.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALDIVES\';\">AIBS Partners<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"partners.php#bec_part\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALDIVES\';\">Become an AIBS Partner<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"partners.php#pc\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALDIVES\';\">Partner Categories<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"partners.php#sc\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALDIVES\';\">Sponsor Categories<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"part_form.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:MALDIVES\';\">Partner Application Form<\/a><\/div> ");

document.writeln("<\/td>");
document.writeln("<td width=20% class=\'sngPst\'>");
document.writeln("<div nowrap>Other Links <\/div> ");
document.writeln("<div nowrap><a href=\"ben.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:NORWAY\';\">Beneficiaries<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"testimony.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:OMAN\';\">Testimonials<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"volunteer.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PAKISTAN\';\">Why Volunteer?<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"volunteer.php#vo\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PANAMA\';\">Volunteering Opportunities<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"volunteer.php#vn\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PARAGUAY\';\">Volunteer Now<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"pg.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PERU\';\">Event Photos<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"hp.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PHILLIPINES\';\">Historical Photos<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"sb.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PHILLIPINES\';\">Score Board<\/a><\/div> ");
document.writeln("<div nowrap><a href=\"hp.php\" class=\'sngPst\' onClick=\"s_objectID=\'R8:WW:PHILLIPINES\';\">Hall Of Fame<\/a><\/div> ");

document.writeln("<\/td>");

document.writeln("<\/td><\/tr>");
document.writeln("<tr><td><\/td><\/tr>");
document.writeln("<\/table>");
document.writeln("<\/div>");
}

// Start of functions used by new Ocom search
function trim(value)
{
  s = new String(value);
  if (value != null) {
    var beginIndex = -1;
    var endIndex   = s.length;

    for (var i = 0; i < s.length; i++)
    {
      if (s.charAt(i) != " ") {
        beginIndex = i;
        break;
      }
    }
    if (beginIndex == -1) return "";

    for (var j = s.length -1; j > beginIndex; j--) {
      if (s.charAt(j) != " ") {
        endIndex = j;
        break;
      }
    }
    if (endIndex != s.length) return s.substring(beginIndex, endIndex);
    else return s.charAt(beginIndex);
  }
  return value;
}

// Special Characters validation
// Added isSplCharsExist() on 25th April 2007 by Girish
var splCharsInKeyword;
function isSplCharsExist(value) {
    splCharsInKeyword = '';     
     var iChars = "!#$%^=;|:?";
        for (var i = 0; i < value.length; i++) {
                if (iChars.indexOf(value.charAt(i)) != -1) {   
                idx = iChars.indexOf(value.charAt(i));
                splCharsInKeyword +=  iChars.charAt(idx) + ' ';

               }
     }
     
     if (splCharsInKeyword == '' || trim(splCharsInKeyword).length == 0 ) {
        return false;
      } 
     else {
        return true;
     }
}

// Serach validation Global value
// Modified isNotNull() on 25th April 2007 by Girish

var isUserInput = false ;
function isNotNull(value)
{
	  if (value == null || trim(value).length == 0  || value == "search site" || value =="Search OPN" || !isUserInput)
	  {
	    alert('You did not enter a search term.  Please try again.');
	    document.searchForm.keyword.value='';
	    isUserInput = true;	    
	    document.searchForm.keyword.focus();
	    return false;
	  }
	  else if (isSplCharsExist(value)) {
	  
		   if (trim(splCharsInKeyword).length > 1 ) {
		     splCharsInKeyword = 'Special characters ' + splCharsInKeyword + ' are ';
		   }
		   else {
		     splCharsInKeyword = 'Special character ' + splCharsInKeyword + ' is ';
		   }
		   
	   alert ( splCharsInKeyword +"not allowed.\n");
	   document.searchForm.keyword.focus();
	   return false;
	  }
	 else
	 return true;
}  
 

function checkSearch( value )
{
  if ( document.searchForm && document.searchForm.datasetId && typeof( langDataSetId ) != 'undefined' && langDataSetId )
  {
    document.searchForm.datasetId.value = langDataSetId;
  }

  if ( value == null || trim(value).length == 0 )
  {
    alert('Please enter the keyword(s) to search for');
    return false;
  }
  else 
  {
    if ( document.searchForm ) document.searchForm.submit();
    return true;
  }
}

function checkGlobalSearch( value )
{
  return checkSearch( value );
}


