//功能说明：检察字符串里是否是合法的email地址
//参数说明：要检察的字符串地址
//返回值说明：0：非法的email格式，1：正确的email地址
function fucCheckemail(a)
{
	var temp1, temp2, str_leng;
	str_leng = a.length;
	temp1 = a.indexOf('@');
	temp2 = a.indexOf('.');
	if((temp1 > 0) && (temp2 >= 0))
	{
		return 1;
	}
	return 0;
}

//Author: 	william
//Date:		2006-11-05
//Function: 	goto the mail Server
function GoToMailServer(theUrl,uName,uPwd)
{
	actionto =  theUrl + "/iclient/sso.asp";
	document.logon.txtmailHosting.value = theUrl;
	document.logon.action=actionto;	
	document.logon.target="_bank";
	document.logon.submit();		
}

//submit 
function GoTo()
{
	var a=document.logon;	
	if(check(a))
	{
		
		var mail = a.userid.value; 
		var pwd = a.passwd.value;
		var index = mail.indexOf("@");
		var len = mail.length;
		var mailright = mail.substring(index,len).toLowerCase();  //=========== All return  to LowerCase. william add 2007-06-08
		var actionto;
		
		//================================================================Begin login.aspx
		//====== A -- G ========

		if(mailright=="@adinstruments-asia.com")	
		{
			GoToMailServer("http://mail.adinstruments-asia.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		else if(mailright=="@aeclight-reel.com")             // add acelight-reel.com  by lisa  2007-4-26                                 
		{
			GoToMailServer("http://mail.aeclight-reel.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-jinhua.com")             // add acelight-reel.com  by lisa  2007-4-26                                 
		{
			GoToMailServer("http://mail.porsche-jinhua.com",mail,pwd);
			return;
		}
		else if(mailright=="@dashbrands.com")             // add mail.dashbrands.com  by william 2009-03-06                                
		{
			GoToMailServer("http://mail.dashbrands.com",mail,pwd);
			return;
		}
		
		else if(mailright=="@prosperitygroup.cn")             // add mail.prosperitygroup.cn 2008-10                                
		{
			GoToMailServer("http://mail.prosperitygroup.cn",mail,pwd);
			return;
		}		
		else if(mailright=="@porsche-dongguan.com")             // add proche-dongguan.com 2008-12                               
		{
			GoToMailServer("http://mail.porsche-dongguan.com",mail,pwd);
			return;
		}
		
		else if(mailright=="@adamas.com.cn")
		{
			GoToMailServer("http://mail.adamas.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@artax.cn")
		{
			GoToMailServer("http://mail.artax.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@asiamedia.net")
		{
			GoToMailServer("http://mail.asiamedia.net",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@asiantigers-china.biz") // ==============================  add in 2007-08-08
		{
			GoToMailServer("http://mail.asiantigers-china.biz",mail,pwd);
			
			return;
		}
		else if(mailright=="@asiantigers-china.com") // ==============================  add in 2007-08-08
		{
			GoToMailServer("http://mail.asiantigers-china.com",mail,pwd);
			//GoToMailServer("http://211.152.151.12",mail,pwd);
			return;
		}
		else if(mailright=="@jinding.com")  // ==============================  add in 2006-12-14
		{
			GoToMailServer("http://mail.jinding.com",mail,pwd);
			//GoToMailServer("http://116.213.96.111",mail,pwd);
			return;
		}	
		else if(mailright=="@triding.com")  // ==============================  add in 2006-12-14
		{
			GoToMailServer("http://mail.triding.com",mail,pwd);
			return;
		}
		else if(mailright=="@asiapro.cn")  // ==============================  add in 2006-12-14
		{
			GoToMailServer("http://mail.asiapro.cn",mail,pwd);
			return;
		}		
		else if(mailright=="@asksam.com.cn")  // =========================== add in 2006-12-14  
		{
			GoToMailServer("http://mail.asksam.com.cn",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			
			return;
		}
		else if(mailright=="@buildoo.com")// =========================== add in 2008-06-10 William 
		{
			GoToMailServer("http://mail.buildoo.com",mail,pwd);
			return;
		}
		else if(mailright=="@bqcchina.com.cn")// =========================== add in 2008-07-25 William 
		{
			GoToMailServer("http://mail.bqcchina.com.cn",mail,pwd);
			return;
		}

		
		else if(mailright=="@bcfii.cn")
		{
			//GoToMailServer("http://210.73.205.202",mail,pwd);	//===== William Remark 2008-12-22
			GoToMailServer("http://mail.bcfii.cn",mail,pwd);	//===== William Remark 2008-12-22
			return;
		}
		else if(mailright=="@cathay-sub.com")          //=========================== add in 2007-4-26                  
		{
			GoToMailServer("http://mail.cathay-sub.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@chinaoffice.biz")          //=========================== add in 2008-4-11                  
		{
			GoToMailServer("http://mail.chinaoffice.biz",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}		
		else if(mailright=="@chinahides.com")	//2008-12-22
		{
			GoToMailServer("http://210.73.205.202",mail,pwd);			
			//GoToMailServer("http://116.213.96.111",mail,pwd);
			return;
		}
		 else if(mailright=="@chinareadycompany.com")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.chinareadycompany.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);	
			return;
		}
	    else if(mailright=="@cicdata.com")          //=========================== add in 2007-4-26                  
		{
			GoToMailServer("http://mail.cicdata.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@ckygroup.com.cn") // ========================= add in 2006-12-14  
		{
			GoToMailServer("http://mail.ckygroup.com.cn",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}	
		else if(mailright=="@designunlimited.com.cn")
		{
			GoToMailServer("http://mail.designunlimited.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}			
		else if(mailright=="@elders.com.cn")
		{
			GoToMailServer("http://mail.elders.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@elecord.com.cn")
		{	
			GoToMailServer("http://mail.elecord.com.cn",mail,pwd);
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;
		}
		else if(mailright=="@elecord.com")// 2006-11-13 add
		{	
			GoToMailServer("http://mail.elecord.com",mail,pwd);
			//GoToMailServer("http://211.152.151.11",mail,pwd);
			return;
		}
		else if(mailright=="@esfc.com.cn")
		{
			GoToMailServer("http://mail.esfc.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		else if(mailright=="@evergreenbatteries.com")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.evergreenbatteries.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		else if(mailright=="@fosterpartners.com.cn")		
		{
			GoToMailServer("http://mail.fosterpartners.com.cn",mail,pwd);
			return;
		}
		else if(mailright=="@fpselection.com.cn")		
		{
			GoToMailServer("http://mail.fpselection.com.cn",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);	
			return;
		}
		
		else if(mailright=="@globalmobility-china.com")		//====================add 2007-08-08
		{
			GoToMailServer("http://mail.globalmobility-china.com",mail,pwd);
			//GoToMailServer("http://211.152.151.12",mail,pwd);	
			return;
		}
		 else if(mailright=="@gifthink-china.com")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.gifthink-china.com",mail,pwd);
			//GoToMailServer("http://116.213.96.111",mail,pwd);	
			return;
		}
		//======= H -- N =======
		
		else if(mailright=="@headlinedevelopment.com.cn")	// ==== Add 2008-09-19 Andy
		{
			//GoToMailServer("http://mail.headlinedevelopment.com.cn",mail,pwd);
			GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@historic-shanghai.com")
		{
			GoToMailServer("http://mail.historic-shanghai.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		
		else if(mailright=="@hutchin.com.cn")
		{	
			GoToMailServer("http://mail.hutchin.com.cn",mail,pwd);
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;
		}
		
		else if(mailright=="@hutchin.com")// 2006-11-13 add	
		{	
			GoToMailServer("http://mail.hutchin.com",mail,pwd);
			//GoToMailServer("http://211.152.151.11",mail,pwd);	
			return;
		}
		 else if(mailright=="@isbchina.cn")// ===============Add by William (2008-02-25)2
		{
			GoToMailServer("http://mail.isbchina.cn",mail,pwd);
			return;
		}
		else if(mailright=="@imanpack.com.cn")// ============Add by William (2008-02-25)1
		{
			GoToMailServer("http://mail.imanpack.com.cn",mail,pwd);
			return;
		}

		else if(mailright=="@smartguy.cn")// ================Add by William (2008-02-25)3
		{
			GoToMailServer("http://mail.Smartguy.cn",mail,pwd);
			return;
		}

		else if(mailright=="@tcstrading.com")// ================Add by William (2008-02-25)4
		{
			GoToMailServer("http://mail.Smartguy.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		else if(mailright=="@yuanlaishini88.com")// ================Add by William (2008-02-25)5
		{
			GoToMailServer("http://mail.yuanlaishini88.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);	
			return;
		}
		
		else if(mailright=="@porsche-haikou.com")// ================Add by William (2008-02-25)6
		{
			GoToMailServer("http://mail.porsche-haikou.com",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-harbin.com")
		{
			GoToMailServer("http://mail.porsche-harbin.com",mail,pwd);
			return;
		}
		
		else if(mailright=="@tracyinshanghai.com")
		{
			GoToMailServer("http://mail.tracyinshanghai.com",mail,pwd);
			return;
		}				
		else if(mailright=="@mingruiku.com")
		{
			GoToMailServer("http://mail.mingruiku.com",mail,pwd);
			return;
		}
		
		
		else if(mailright=="@shanghaigifted.com")	//=================Add by Wallace(2008-02-18) =========	
		{
			GoToMailServer("http://mail.shanghaigifted.com/",mail,pwd);
			return;
		}


		else if(mailright=="@isabellatsiknas.com")// 2008-02-05 add by william
		{	
			GoToMailServer("http://mail.isabellatsiknas.com",mail,pwd);			
			return;
		}		

		else if(mailright=="@iclp.com.cn")
		{
			GoToMailServer("http://mail.iclp.com.cn",mail,pwd);
			return;
		}
	    else if(mailright=="@imanpack.com.cn")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.imanpack.com.cn",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);	
			return;
		}
		else if(mailright=="@jiezu.com")
		{	
			GoToMailServer("http://mail.jiezu.com",mail,pwd);	
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;
		}
		else if(mailright=="@jjmshanghai.com")
		{
			GoToMailServer("http://mail.jjmshanghai.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@miraclemandarin.com")		
		{
			GoToMailServer("http://mail.miraclemandarin.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@nrges.ie") 
		{
			GoToMailServer("http://mail.nrges.ie",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		//=========== O -- Z ========== 
		//osborne-asia.com"(211.152.149.206)  === 2007-01-04
		else if(mailright=="@osborne-asia.com") //add in 2006-12-19
		{
			GoToMailServer("http://mail.osborne-asia.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@overtonsolutions.com")
		{
			GoToMailServer("http://mail.overtonsolutions.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@petexpress-china.com") //================2007-08-08===========================
		{
			GoToMailServer("http://mail.petexpress-china.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-ningbo.com") //================2008-08-03 by William Begin===========================
		{
			GoToMailServer("http://mail.porsche-ningbo.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-bj-haidian.com") //================2008-08-03 by William===========================
		{
			GoToMailServer("http://mail.porsche-bj-haidian.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-changsha.com") //================2008-08-03 by William===========================
		{
			GoToMailServer("http://mail.porsche-changsha.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-fuzhou.com") 
		{
			GoToMailServer("http://mail.porsche-fuzhou.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}	//================2008-08-03 by William End===========================
		else if(mailright=="@porsche-beijing1.com")		
		{
			GoToMailServer("http://mail.porsche-beijing1.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-beijing3s.com")		   //=========================== add in 2007-4-26  
		{
			GoToMailServer("http://mail.porsche-beijing3s.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-club-shanghai.com") // 2006-11-17 add by william
		{
			GoToMailServer("http://mail.porsche-club-shanghai.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
			else if(mailright=="@porsche-beijing2.com")		
		{
			GoToMailServer("http://mail.porsche-beijing2.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-chengdu.com")		
		{
			GoToMailServer("http://mail.porsche-chengdu.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-zhengzhou.com")		
		{
			GoToMailServer("http://mail.porsche-zhengzhou.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-chongqing.com")		
		{
			GoToMailServer("http://mail.porsche-chongqing.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-dalian.com")		
		{
			GoToMailServer("http://mail.porsche-dalian.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-guangzhou.com")		
		{
			GoToMailServer("http://mail.porsche-guangzhou",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-hangzhou.com")		
		{
			GoToMailServer("http://mail.porsche-hangzhou.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-liaoning.com") // 2006-12-14 add 
		{
			GoToMailServer("http://mail.porsche-liaoning.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-qingdao.com")		
		{
			GoToMailServer("http://mail.porsche-qingdao.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-shenyang.com")		
		{
			GoToMailServer("http://mail.porsche-shenyang.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-shengyang.cn")		//=========================== add in 2007-4-26  
		{
			GoToMailServer("http://mail.porsche-shengyang.cn",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-shanghai.com")		
		{
			GoToMailServer("http://mail.porsche-shanghai.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-xiamen.com")		
		{
			GoToMailServer("http://mail.porsche-xiamen.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-wuhan.com")		
		{
			GoToMailServer("http://mail.porsche-wuhan.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-nanjing.com")                            //2007-04-16 lisa		
		{
			GoToMailServer("http://mail.porsche-nanjing.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-wenzhou.com")                            //========================add 2007-08-07		
		{
			GoToMailServer("http://mail.porsche-wenzhou.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}

		else if(mailright=="@porsche-xian.com")		//=========================== add in 2007-4-26  
		{
			GoToMailServer("http://mail.porsche-xian.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-tianjin.com")		//=========================== add in 2007-4-26  
		{
			GoToMailServer("http://mail.porsche-tianjin.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@porsche-kunming.com")		//=========================== add in 2007-4-26  
		{
			GoToMailServer("http://mail.porsche-kunming.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@prestige-voyages.com")
		{
			GoToMailServer("http://mail.prestige-voyages.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@pts-asia.com")
		{
			GoToMailServer("http://mail.pts-asia.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@robartsinteriors.com")
		{
			GoToMailServer("http://mail.robartsinteriors.com",mail,pwd);
			return;
		}
		else if(mailright=="@rsadesign.com.cn")   //William Edit 2008-09-06
		{
			document.logon.action="http://mail.rsadesign.com.cn/exchange";	
			document.logon.target="_bank";
			document.logon.submit();
			
			//GoToMailServer("http://mail.rsadesign.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@rthree.com.cn")	
		{
			GoToMailServer("http://mail.rthree.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@rthree.cn")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.rthree.cn",mail,pwd);
			return;
		}
		else if(mailright=="@samritter.com" ) // ===============none 2007-01-07	
		{	
			GoToMailServer("http://mail.samritter.com",mail,pwd);
			return;	
		}
		else if(mailright=="@searchbank.cn")
		{
			GoToMailServer("http://mail.searchbank.cn",mail,pwd);
			return;
		}
        else if(mailright=="@search-flow.com")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.search-flow.com",mail,pwd);
			return;
		}
		else if(mailright=="@sgcellardoor.com")  //================= none (2007-01-07) =========
		{
			GoToMailServer("http://mail.sgcellardoor.com",mail,pwd);
			return;
		}
		else if(mailright=="@shmag.cn")	// add 2006-11-07	
		{
			GoToMailServer("http://mail.shmag.cn",mail,pwd);
			return;
		}
		else if(mailright=="@shashipping.com")
		{
			GoToMailServer("http://mail.shashipping.com",mail,pwd);
			return;
		}
		else if(mailright=="@shanghai-events.com")
		{
			GoToMailServer("http://mail.shanghai-events.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@sinojie.com")
		{
			GoToMailServer("http://mail.sinojie.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		
		else if(mailright=="@smartlinkus.com")
		{
			GoToMailServer("http://mail.smartlinkus.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@ssbglist.com")
		{
			GoToMailServer("http://mail.ssbglist.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@summergate.com")
		{
			GoToMailServer("http://mail.summergate.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		
		else if(mailright=="@solutions-china.com") //==================2007-08-08==========================
		{
			GoToMailServer("http://mail.solutions-china.com",mail,pwd);
			//GoToMailServer("http://116.213.96.116",mail,pwd);
			return;
		}
		else if(mailright=="@ssbgit.com" ) 		
		{	
			GoToMailServer("http://mail.ssbgit.com",mail,pwd);
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;	
		}
	    else if(mailright=="@ssbgit.com.hk" ) 	//================ none (2007-01-07)	
		{	
			GoToMailServer("http://mail.ssbgit.com.hk",mail,pwd);
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;	
		}
		else if(mailright=="@ssbg-china.com" )	
		{	
			GoToMailServer("http://mail.ssbg-china.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;	
		}	
		else if (mailright=="@ssbg.com") //2008-09-06 william
		{
			document.logon.action="http://mail.ssbg.com/exchange";	
			document.logon.target="_bank";
			document.logon.submit();
			return;
		}
		else if (mailright=="@ssbg.com.cn")
		{
			//alert("http://mail.ssbg.com.cn/iclient");
			//GoToMailServer("http://mail.ssbg.com.cn/iclient",mail,pwd);
			GoToMailServer("http://mail.ssbg.com.cn",mail,pwd);

			return;
		}
		else if (mailright=="@ssbg.com.hk")   ///-------------------------------add 2007-08-07
		{
			GoToMailServer("http://mail.ssbg.com.hk",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if (mailright=="@ssbg.cn") //=====================================add 2007-7-23
		{
			GoToMailServer("http://mail.ssbg.cn",mail,pwd);
			//GoToMailServer("http://mail.ssbg.cn",mail,pwd);
			return;
		}
		
		else if(mailright=="@ssbglist.com" ) 	// =============== none 2007-01-07	
		{	
			GoToMailServer("http://mail.ssbglist.com",mail,pwd);
			//GoToMailServer("http://61.152.172.178",mail,pwd);
			return;	
		}
		else if (mailright=="@stromag-china.com") // ===============add 2007-01-04
		{
			GoToMailServer("http://mail.stromag-china.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@stshanghai.com")
		{
			GoToMailServer("http://mail.stshanghai.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@summergate.com")
		{
			GoToMailServer("http://mail.summergate.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@summergate.com.hk" ) //=================none (2007-01-07) 		
		{	
			GoToMailServer("http://mail.summergate.com.hk",mail,pwd);
			//GoToMailServer("http://202.64.181.48",mail,pwd);
			return;	
		}
		else if(mailright=="@synthesisenergy.com")
		{
			GoToMailServer("http://mail.synthesisenergy.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@technomicasia.com")		
		{
			GoToMailServer("http://mail.technomicasia.com",mail,pwd);
			//GoToMailServer("http://210.14.66.33",mail,pwd);
			return;
		}
		else if(mailright=="@thesalzergroupsh.com")
		{
			GoToMailServer("http://mail.thesalzergroupsh.com",mail,pwd);
			return;
		}
		else if(mailright=="@thaifoodstation.com")	
		{
			GoToMailServer("http://mail.thaifoodstation.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@treasuryholdingschina.com")	
		{
			GoToMailServer("http://mail.treasuryholdingschina.com",mail,pwd);
			//GoToMailServer("http://211.152.149.152",mail,pwd);
			return;
		}
		else if(mailright=="@tmi.sh")	//2008-03-12 william
		{
			GoToMailServer("http://mail.tmi.sh",mail,pwd);
			//GoToMailServer("http://211.152.149.152",mail,pwd);
			return;
		}		
		else if(mailright=="@wedgwood.com.cn")
		{
			GoToMailServer("http://mail.wedgwood.com.cn",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@wessco-cn.net")
		{
			GoToMailServer("http://mail.wessco-cn.net",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}
		else if(mailright=="@yessamin.com")
		{
			GoToMailServer("http://mail.yessamin.com",mail,pwd);
			//GoToMailServer("http://211.152.149.206",mail,pwd);
			return;
		}			
		else 
		{
			actionto = "";
			alert("Your domain doesn't exists in our web Mail!Please contact your email administrator");
			return false;			
		}
		
		if(actionto != "")
		{
			document.logon.action=actionto;
			document.logon.target="_bank";
			document.logon.submit();
		}
	}
}

//Check input's Value
function check(a)
{//验证转页的条件
	if(!a.userid.value)
	{//检查是否有输入
		alert("Please input your email address!");
		a.userid.focus();
		return false;
	}

	if(!a.passwd.value)
	{//检查是否有输入
		alert("Please input your password!");
		a.passwd.focus();
		return false;
	}	
	if(!fucCheckemail(a.userid.value))
	{
		alert("Please input your email address!");
		a.userid.focus();
		return false;
	}	
	return true;
}

function GoUrl(EmailPostfix)
{
	switch(postfix)
	{
		case "@ssbg.com.cn":		
			actionto="http://mail.ssbg.com.cn/login.cgi";			
			document.logon.action=actionto;
			document.logon.submit();
			break;
	}
}



	   
