/* author: marvin_stewart@hotmail.com */
/* Creation date: 2003-07-14 */


/*************************************/

function getemployeeplan(EMPLOYEEPLANLOOKUP,planid) {


   
   if(7 != planid.length){
      /* Plan ID Not 7 Characters Long */
         
      alert("Please re-enter the first seven characters \r(letters and numbers) that appear on your ID card.")

   }
   else {

      if(-1 == displayplanpage(EMPLOYEEPLANLOOKUP,planid))
         {
            /* Plan ID Not Found */

            alert("Plan ID not found.  Please check your ID number.")
         }

   }
      

}


/*************************************/

function displayplanpage(EMPLOYEEPLANLOOKUP,planid) {

  
  for(var p = 0; p < EMPLOYEEPLANLOOKUP.length; p++) {
		  
		    /* Plan ID */

		    if(planid.substring(0,2) == EMPLOYEEPLANLOOKUP[p][0]){
			 /* Found plan id */
                   
                       window.location = "http://www.dentalnowonline.com" + EMPLOYEEPLANLOOKUP[p][1] 
                       return(1)
			   
			   }	
  }		
		                
  return(-1)
		
}
