﻿// JScript File

function emailfriend(){

   var newhref=bupa_web_site_url+"/b5/contact_bupa/forward_friends.aspx?fromurl="+escape(window.location.href);
   window.location.href=newhref;



}

function jumphttps(url){
   var href=bupa_web_site_url_https+url;
   window.location.href=href;
   
}

function jumphttp(url){
     var href=bupa_web_site_url+url;
      window.location.href=href;


}

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 pageToEn(){
    var lastURL=window.location.href;
    var newURL=lastURL.replace('/b5/','/en/');
    window.location.href=newURL;
}

function pageToB5(){
    var lastURL=window.location.href;
    var newURL=lastURL.replace('/en/','/b5/');
    window.location.href=newURL;
}

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 MM_findObj(n, d) { //v4.01
  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);
  if(!x && d.getElementById) x=d.getElementById(n); 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];}
}

// JScript File

 function EnterTextBox(button,evt)
   {
        evt = evt ? evt : (window.event ? window.event : null);
       var currentKey = evt.charCode||evt.keyCode;
        if(currentKey==13)
        {
            var obj=document.getElementById(button);
            if(navigator.userAgent.indexOf("MSIE")>0) {
                evt.returnValue = false;
                obj.click();
            }
            if(isFirefox=navigator.userAgent.indexOf("Firefox")>0){
                 evt.preventDefault();
//                obj.fireEvent("onclick");  
//            obj.click(evt);
            } 
        } 
   }  
    var fontSize = 14;
    function print_onclick() {
        var bdhtml=window.document.body.innerHTML;
        //alert(bdhtml.length);//4619
        var sprnstart="<!--startprint-->";
        var sprnend="<!--endprint-->";
        //alert(bdhtml.indexOf(sprnstart)+17);//582
        var sprnhtml=bdhtml.substring(bdhtml.indexOf(sprnstart)+17,bdhtml.length);               
        //alert(sprnhtml.indexOf(sprnend));//3246
        sprnhtml=sprnhtml.substring(0,sprnhtml.indexOf(sprnend));
        /*open new page print
        window.document.body.innerHTML=sprnhtml;
        window.print();
        */      
        
        document.body.innerHTML = '<div style="width:600px">' + sprnhtml + '</div>'; 
        window.print();
        window.history.go(0);

    }
    function doZoom(size)
    {
        if(size != 0) fontSize = size + fontSize;
        else fontSize = 14;
        document.body.style.fontSize = fontSize + "px";
    } 
    function forwardtofriend(thisurl,getUri)
    {
        var sendMail=window.open("ForwardToFriend.html","告知好友","toolbar =no, menubar=no, scrollbars=no, resizable=no, location=no, status=no,width=300,height=120");
        sendMail.document.write("<html><head><style type='text/css'>body{font-size:14px;}</style></head><body><form method='get' action='" + 
                                getUri + "'>好友姓名:<input name='name' /><br/>好友郵箱:<input name='email' /><br/><input type='submit' value='發送'/>" +
                                "<input type='hidden' name='thisuri' value='" + thisurl + "' /></form></body></html>");
        sendMail.document.close();
    }
   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 MM_findObj(n, d) { //v4.01
      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);
      if(!x && d.getElementById) x=d.getElementById(n); 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 parseUri(sourceUri){
	var uriPartNames = ["source","protocol","authority","domain","port","path","directoryPath","fileName","query","anchor"],
		uriParts = new RegExp("^(?:([^:/?#.]+):)?(?://)?(([^:/?#]*)(?::(\\d*))?)((/(?:[^?#](?![^?#/]*\\.[^?#/.]+(?:[\\?#]|$)))*/?)?([^?#/]*))?(?:\\?([^#]*))?(?:#(.*))?").exec(sourceUri),
		uri = {};
	
	for(var i = 0; i < 10; i++){
		uri[uriPartNames[i]] = (uriParts[i] ? uriParts[i] : "");
	}
	
	/* Always end directoryPath with a trailing backslash if a path was present in the source URI
	Note that a trailing backslash is NOT automatically inserted within or appended to the "path" key */
	if(uri.directoryPath.length > 0){
		uri.directoryPath = uri.directoryPath.replace(/\/?$/, "/");
	}
	
	return uri;
}






function quickdoReset() {
	 document.getElementById("quickage").value="";
	 document.getElementById("error").innerHTML="";
     if(document.getElementById("quickbenefit"))
	 document.getElementById("quickbenefit").selectedIndex=0;
	 return false;
     
}

function quickcheckIsInteger(str) {
    if(str == "")
        return true;
    if(/^(\-?)(\d+)$/.test(str))
        return true;
    else
        return false;
}

function quickdoSubmit() {
        var uri =parseUri(window.location.href);
  	// Start check the age
	theAge =document.getElementById("quickage").value;
	theError = document.getElementById("error");
	benefit=1;
	if(document.getElementById("quickbenefit"))          
	   benefit=document.getElementById("quickbenefit").selectedIndex+1;             
	else{           
            if(document.getElementById("select")){
                 benefit=document.getElementById("select").selectedIndex+1;   
           }
        }       
	href="";	
	if(theAge != "" && quickcheckIsInteger(theAge)) {
		theAge = parseInt(theAge);
	    var path=uri.path.toLowerCase();	
	    //alert(path);
	    if( /bupa\_care\_pro\.aspx/.test(path) ||  /Care\_Pro\_IQ\.aspx/.test(path) ){
	        
	        if(theAge >= 18 && theAge <= 100) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Care_Pro_IQ.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		       if(theAge>100)
		        alert("請輸入年齡在18至100之間。");	
		      else
		        alert("此計劃為年屆18歲或以上人士而設。如建議受保人為17歲或以下，請選擇「保柏童康健」計劃。");
		    
		      document.getElementById("quickage").focus();
		      //theError.innerHTML = "請輸入年齡在18和100之間。";
			  return ;
		
		   }  
	       
	    }else if( /bupa\_care\_kid\.aspx/.test(path) || /Care\_Kid\_IQ\.aspx/.test(path) ){
	        
	        if(theAge >= 0 && theAge <18) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Care_Kid_IQ.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		      alert("此計劃為年屆15日至17歲之人士而設。如建議受保人為18歲或以上，請選擇「保柏卓康健」計劃。");
		      document.getElementById("quickage").focus();
		      //theError.innerHTML = "請輸入年齡在0和17之間。";
			  return ;
		
		   }  
	       
	   }else if( /bupa\_care\_healthnet\.aspx/.test(path) ||   /medical\_Insurance\/healthnet\.aspx/.test(path)){
	        // care healthnet
	        if(theAge >= 18 && theAge <=59) {
		      href=bupa_web_site_url_https+"/b5/quickquote/HealthNet.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		      alert("此計劃為年介18至59歲之人士而設。17歲或以下之兒童須與其中一名父母投保。59歲以上人士請選擇「保柏卓康健」計劃。");
		      //theError.innerHTML = "請輸入年齡在18和59之間。";
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	   }else if( /bupa\_crystal\.aspx/.test(path) || /crystal\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 18 && theAge <=59) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Crystal.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		   }else
		   {
		      alert("此計劃為年介18至59歲之人士而設。17歲或以下之兒童須與其中一名父母投保。59歲以上人士請選擇「保柏卓康健」計劃。");
		      // theError.innerHTML = "請輸入年齡在18和59之間。";
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	 
	   }else if( /bupa\_gold\.aspx/.test(path) || /gold\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 18 && theAge <=59) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Gold.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
                      
		
		    }else
		    {
		      alert("此計劃為年介18至59歲之人士而設。17歲或以下之兒童須與其中一名父母投保。59歲以上人士請選擇「保柏卓康健」計劃。");
		      //theError.innerHTML = "請輸入年齡在18和59之間。";
			  return ;
	
		   }  
	       
	   } else if( /bupa\_civil\_servants\.aspx/.test(path) || /civil\_servants\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 18 && theAge <=64) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Civil_Servants.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		      alert("此計劃為年介18至64歲之公務員而設。64歲以上人士請選擇「保柏卓康健」計劃。17歲或以下之兒童須與其中一名父母投保。");
		      document.getElementById("quickage").focus();
		      //theError.innerHTML = "請輸入年齡在18和64之間。";
			  return ;
		
		   }  
	       
	   } else if( /bupa\_wise\_choice\.aspx/.test(path) || /wise\_choice\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 18 && theAge <=54) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Wise_Choice.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		      alert("此計劃為年介18至54歲之人士而設。17歲或以下之兒童須與其中一名父母投保。54歲以上人士請選擇「保柏卓康健」計劃。");
		      document.getElementById("quickage").focus();
		      //theError.innerHTML = "請輸入年齡在18和49之間。";
			  return ;
		
		   }  
	       
	   }else if( /choice\_plus\.aspx/.test(path) || /bupa\_choice\_plus\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 5 && theAge <=50) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Choice_plus.aspx?empnum="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		      if(theAge<5)
		        alert("此計劃為最少有5名僱員的公司而設。您或可考慮我們的個人醫療保障計劃或致電2517 5860查詢。");
		      else
		        alert("此標準團體保障計劃為最多有50名僱員的公司而設。請致電2517 5338查詢有關度身訂做團體保障計劃的詳情。");  
		     // theError.innerHTML = "請員工人數在5和50之間。";
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	   }
	   else if( /enterprise\_healthnet\.aspx/.test(path) || /bupa\_enterprise\_healthnet\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 5 && theAge <=50) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Enterprise_HealthNet.aspx?empnum="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		       if(theAge<5)
		        alert("此計劃為最少有5名僱員的公司而設。您或可考慮我們的個人醫療保障計劃或致電2517 5860查詢。");
		      else
		        alert("此標準團體保障計劃為最多有50名僱員的公司而設。請致電2517 5338查詢有關度身訂做團體保障計劃的詳情。");  
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	   }else if( /corporate\_healthnet\.aspx/.test(path) || /bupa\_corporate\_healthnet\_plus\.aspx/.test(path)){
	        //crystal
	        if(theAge >= 5 && theAge <=50) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Corporate_HealthNet.aspx?empnum="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		    }else
		    {
		       if(theAge<5)
		        alert("此計劃為最少有5名僱員的公司而設。您或可考慮我們的個人醫療保障計劃或致電2517 5860查詢。");
		      else
		        alert("此標準團體保障計劃為最多有50名僱員的公司而設。請致電2517 5338查詢有關度身訂做團體保障計劃的詳情。");  
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	   }
	   else if( /group\_medical\_insurance\.aspx/.test(path) ){
	        //crystal
	        if(theAge >= 5 && theAge <=50) {
		       href=bupa_web_site_url_https+"/b5/quickquote/Corporate_HealthNet.aspx?empnum="+theAge+"&benefit="+benefit;		  
		       window.location.href=href;
		       return ;
		
		    }else
		    {
		      if(theAge<5)
		        alert("此計劃為最少有5名僱員的公司而設。您或可考慮我們的個人醫療保障計劃或致電2517 5860查詢。");
		      else
		        alert("此標準團體保障計劃為最多有50名僱員的公司而設。請致電2517 5338查詢有關度身訂做團體保障計劃的詳情。");  
			  document.getElementById("quickage").focus();
			  return ;
		
		   }  
	       
	   }
	   else{ 
	    
	    //start carepro and care kid part 
	   // if(path=="/b5/index.aspx" || /customer\_care/.test(path) || path=="" ){	    	    
	          
	     
	     
	     
	     
	     
	  if(benefit <= 2 ){ 
	     if(theAge >= 18 && theAge <= 100) {
		      href=bupa_web_site_url_https+"/b5/quickquote/Care_Pro_IQ.aspx?age="+theAge+"&benefit="+benefit;		  
		      window.location.href=href;
		      return ;
		
		  } else if (theAge > 100) {
			  //theError.innerHTML = "請輸入年齡在0和100之間。";
			   alert("請輸入年齡在18和100之間。");
			   document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
			   return;
		  } else if(theAge >=0) {
		       href=bupa_web_site_url_https+"/b5/quickquote/Care_Kid_IQ.aspx?age="+theAge+"&benefit="+benefit;		   
		       window.location.href=href;
		  } else{
		       alert("請輸入年齡在0和100之間。");
		       document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
			   return ;
		
		  }  
	}else{
		
		
		    
         if(theAge >59) {
		       alert("此計劃為年屆59歲或以下人士而設。");
		       document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
		       return ;
		  } else if(theAge >=0) {
		      
		  } else{
		       alert("請輸入年齡在0和59之間。");
		       document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
			   return ;
		
		  } 
	      var sa =document.getElementById("sa").value;        
          if(sa != "" && quickcheckIsInteger(sa)){
                  
           }else{
           alert("請選擇保障金額。");
		   document.getElementById("sa").value=""; 	
		   document.getElementById("sa").focus();
		   return;        
          }        
          sa=parseInt(sa);		  		  
		  if(sa >=200000 && sa<= 1500000) {	     
		   
		  }else{
		       alert("保障金額為港幣20萬至150萬。");
		       document.getElementById("sa").value=""; 	
		       document.getElementById("sa").focus();
			   return ;		
		 }          
         var smoke ="no";
         href=bupa_web_site_url_https+"/b5/quickquote/CII.aspx?age="+theAge+"&sa="+sa+"&smoke="+smoke;
         window.location.href=href;
	 }
			  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
		  
	      
	    
	   
	}	
	  
	  //start 
	  
	  
		
		
} else {
		alert("請輸入整數。");
		document.getElementById("quickage").value=""; 	
		document.getElementById("quickage").focus();
		return;
	}

	
}

function index_quickquote_onchange(select){
      var tr1=document.getElementById("sa_tr_1");
      var tr2=document.getElementById("sa_tr_2");
      if(select.selectedIndex !=2 ){
         if(tr1.style){
           tr1.style.display="none";
           tr2.style.display="none";
         }else{
           tr1.display="none";
           tr2.display="none";
          }
      }else{
      
         if(tr1.style){
           tr1.style.display="";
           tr2.style.display="";
         }else{
           tr1.display="";
           tr2.display="";
          }
      
      
      
      
      }

}


function quickdoSubmit_cii(){

      var  theAge =document.getElementById("quickage").value;       
      if(theAge != "" && quickcheckIsInteger(theAge)) 
        {
                  
        }else{
           alert("請輸入您的年齡。");
		   document.getElementById("quickage").value=""; 	
		   document.getElementById("quickage").focus();
		   return;
        
        }
                        
     
         theAge = parseInt(theAge); 
         if(theAge >59) {
		       alert("此計劃為年屆59歲或以下人士而設。");
		       document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
		      return ;
		  } else if(theAge >=0) {
		      
		  } else{
		       alert("請輸入年齡在0和59之間。");
		       document.getElementById("quickage").value=""; 	
		       document.getElementById("quickage").focus();
			   return ;
		
		  }  
		  
		  
		  
	  var sa =document.getElementById("sa").value;        
      if(sa != "" && quickcheckIsInteger(sa)) 
        {
                  
         }else{
           alert("請選擇保障金額。");
		   document.getElementById("sa").value=""; 	
		   document.getElementById("sa").focus();
		   return;
        
        }        
         sa=parseInt(sa);
		  		  
		  if(sa >=200000 && sa<= 1500000) {	     
		   
		  } else{
		       alert("保障金額為港幣20萬至150萬。");
		       document.getElementById("sa").value=""; 	
		       document.getElementById("sa").focus();
			   return ;
		
		  }  
         var smoke=document.getElementById("smoke").value;

         href=bupa_web_site_url_https+"/b5/quickquote/CII.aspx?age="+theAge+"&sa="+sa+"&smoke="+smoke;
         
               		   
	 window.location.href=href;


}
function quickdoReset_cii(){
      document.getElementById("quickage").value="";
      document.getElementById("sa").value="";
      document.getElementById("smoke").selectedIndex=1;
      
 
}

function age_keypress_cii(e){  
    // get event if not passed
    if (!e) var e = window.event;
    // get character code of key pressed
    if (e.keyCode) numCharCode = e.keyCode;
    else if (e.which) numCharCode = e.which;
    //alert(numCharCode);
    if(numCharCode==13){
        quickdoSubmit_cii();
        return false;
    }

      

}





function age_keypress(e){  
    // get event if not passed
    if (!e) var e = window.event;
    // get character code of key pressed
    if (e.keyCode) numCharCode = e.keyCode;
    else if (e.which) numCharCode = e.which;
    //alert(numCharCode);
    if(numCharCode==13){
        quickdoSubmit();
        return false;
    }
/*
    if(numCharCode>=48 && numCharCode<=57)
    {       
      return true;
    }else{
      return false;
    }
*/        

}
function age_handle_gold(){
        var uri =parseUri(window.location.href);  	
	theAge =document.getElementById("quickage").value;
        if(theAge != "" && quickcheckIsInteger(theAge)) {
	   theAge = parseInt(theAge);
	   var path=uri.path.toLowerCase();
           if(document.getElementById("quickbenefit"))          
	      benefit=document.getElementById("quickbenefit");          
	   else {
           
            if(document.getElementById("select")){
                 benefit=document.getElementById("select");
            }
           }           	   
	   if(theAge >= 18 && theAge <=49) {	
                      //alert("less than 49");                          
                      if(benefit.options.length==2){
                       //add options
                       //alert("add options");
                       benefit.options.add(new Option("住院及手術保障+產科保障","3"));
                      }
		
	    }
            if(theAge>=50 && theAge<=59){
                    
                       if(benefit.options.length==3){
                         //add options
                         benefit.remove(2);
                      }
           }
           
       }

}


/************************************************8
* event handle function here
**
**/

function addEvent(obj, type, fn, name_hash)
{
	if (obj.addEventListener){
		obj.addEventListener( type, fn, false );		
	}		
	else if (obj.attachEvent)
	{
		//alert(type);
        obj["e"+type+fn+name_hash] = fn;
		obj[type+fn+name_hash] = function() { obj["e"+type+fn+name_hash]( window.event ); }
		obj.attachEvent( "on"+type, obj[type+fn+name_hash] );
        //obj.attachEvent( "on"+type, fn );  
	}
}

function removeEvent(obj, type, fn, name_hash)
{
	if (obj.removeEventListener)
		obj.removeEventListener( type, fn, false );
	else if (obj.detachEvent)
	{
		obj.detachEvent( "on"+type, obj[type+fn+name_hash] );
		//obj.detachEvent( "on"+type, fn );
		obj[type+fn+name_hash] = null;
		obj["e"+type+fn+name_hash] = null;
	}
}

function windowonload(){
        var uri =parseUri(window.location.href);  	
	var path=uri.path.toLowerCase();    
        //alert("path="+path);    
        if(/bupa\_gold\.aspx/.test(path) || /gold\.aspx/.test(path)){
             var quickage=document.getElementById("quickage");
             //alert(quickage);
             addEvent(quickage,"blur",age_handle_gold);
        }

}
//addEvent(window,"load",windowonload);
function search_keypress(e){
   if (!e) var e = window.event;
    // get character code of key pressed
    if (e.keyCode) numCharCode = e.keyCode;
    else if (e.which) numCharCode = e.which;
    if(numCharCode==13){
        search_submit();
        return false;
    }

}
function search_submit(){
    var href=bupa_web_site_url+"/b5/searchInfo/index.aspx?q="+escape(document.getElementById('searchKey').value);               		   
	window.location.href=href;

}