function chkLogin(){
	var username = document.showLogin.username.value;
	var password = document.showLogin.password.value;
	var loginType = document.showLogin.entry.value;
	if(username.length < 1 || username.length > 30){
		alert("用户名非法，请检查!");
		return false;
	}
	if(password.length < 1 || password.length > 30){
		alert("密码非法，请检查!");
		return false;
	}
	if(loginType == "null"){
		alert("您还没有选择要登录到哪里，请您选择去向！");
		sina.$("loginFldselectop").style.display = "block";
		sina.addEvent(document.body,"mousedown",LoginSelectClickOther);
		return false;
	}
	if(loginType == "263mail"){  //263.sina.com只接受帐号@之前的部分
		var p = username.indexOf("@");
		var u = p == -1 ? username : username.substr(0, p);
		document.form_04.u.value = u;
		document.form_04.psw.value = password;
		document.form_04.submit();
		document.showLogin.password.value = "";
		return false;
	}
	if(username.indexOf("@") == -1 && loginType == "vipmail"){
		document.showLogin.username.value += "@vip.sina.com";
	}
	document.showLogin.submit();
	document.showLogin.password.value = "";
	return false;
}

function chkLoginType(username){
	username = username.toLowerCase();
	if(username.indexOf("@") != -1){
		sina.$("L_freemail").className = "disabled";
		sina.$("L_freemail").onclick = null;
		sina.$("L_vipmail").className = "disabled";
		sina.$("L_vipmail").onclick = null;
		sina.$("L_2008mail").className = "disabled";
		sina.$("L_2008mail").onclick = null;
		sina.$("L_263mail").className = "disabled";
		sina.$("L_263mail").onclick = null;
	}else{
		sina.$("L_freemail").className = "";
		sina.$("L_freemail").onclick = function(){LoginSelect("freemail")};
		sina.$("L_vipmail").className = "";
		sina.$("L_vipmail").onclick = function(){LoginSelect("vipmail")};
		sina.$("L_2008mail").className = "";
		sina.$("L_2008mail").onclick = function(){LoginSelect("2008mail")};
		sina.$("L_263mail").className = "";
		sina.$("L_263mail").onclick = function(){LoginSelect("263mail")};
		return;
	};
	if(username.indexOf("@sina.com") != -1){
		sina.$("L_freemail").className = "";
		sina.$("L_freemail").onclick = function(){LoginSelect("freemail")};
		LoginSelect("freemail");
	};
	if(username.indexOf("@vip.sina.com") != -1){
		sina.$("L_vipmail").className = "";
		sina.$("L_vipmail").onclick = function(){LoginSelect("vipmail")};
		LoginSelect("vipmail");
	};
	if(username.indexOf("@2008.sina.com") != -1){
		sina.$("L_2008mail").className = "";
		sina.$("L_2008mail").onclick = function(){LoginSelect("2008mail")};
		LoginSelect("2008mail");
	};
	if(username.indexOf("@263.sina.com") != -1){
		sina.$("L_263mail").className = "";
		sina.$("L_263mail").onclick = function(){LoginSelect("263mail")};
		LoginSelect("263mail");
	};
};

var sina = {
	$ : function(objName){if(document.getElementById){return eval('document.getElementById("'+objName+'")')}else{return eval('document.all.'+objName)}},
	isIE : navigator.appVersion.indexOf("MSIE")!=-1?true:false,
	addEvent : function(obj,eventType,func){if(obj.attachEvent){obj.attachEvent("on" + eventType,func);}else{obj.addEventListener(eventType,func,false)}},
	delEvent : function(obj,eventType,func){
		if(obj.detachEvent){obj.detachEvent("on" + eventType,func)}else{obj.removeEventListener(eventType,func,false)}
	},
	readCookie : function(l){var i="",I=l+"=";if(document.cookie.length>0){offset=document.cookie.indexOf(I);if(offset!=-1){offset+=I.length;end=document.cookie.indexOf(";",offset);if(end==-1)end=document.cookie.length;i=unescape(document.cookie.substring(offset,end))}};return i},
	writeCookie : function(O,o,l,I){var i="",c="";if(l!=null){i=new Date((new Date).getTime()+l*3600000);i="; expires="+i.toGMTString()};if(I!=null){c=";domain="+I};document.cookie=O+"="+escape(o)+i+c}
};
function LoginSelectClickOther(e){
	thisObj = e.target?e.target:event.srcElement;
	do{
		if(thisObj.id == "loginFldselect" || thisObj == document.showLogin.password) return;
		if(thisObj.tagName == "BODY"){LoginSelectClose();return;};
		thisObj = thisObj.parentNode;
	}while(thisObj.parentNode);
};
function clickLoginSelect(){
	if(sina.$("loginFldselectop").style.display == "block"){
		LoginSelectClose();
	}else{
		sina.$("loginFldselectop").style.display = "block";
		sina.addEvent(document.body,"mousedown",LoginSelectClickOther);
	}
};
function LoginSelectClose(){
	sina.$("loginFldselectop").style.display = "none";
	sina.delEvent(document.body,"mousedown",LoginSelectClickOther);
};
function LoginSelect(title){
	var titleName;
	switch(title){
		case "freemail":
			document.showLogin.entry.value = "freemail";
			titleName = "免费邮箱";
			break;
		case "vipmail":
			document.showLogin.entry.value = "vipmail";
			titleName = "VIP邮箱";
			break;

		case "2008mail":
			document.showLogin.entry.value = "2008mail";
			titleName = "2008邮箱";
			break;
		case "263mail":
			document.showLogin.entry.value = "263mail";
			titleName = "同名邮箱";
			break;
		case "blog":
			document.showLogin.entry.value = "blog";
			titleName = "博客";
			break;
		case "vblog":
			document.showLogin.entry.value = "vblog";
			titleName = "播客";
			break;
		case "photo":
			document.showLogin.entry.value = "photo";
			titleName = "相册";
			break;
		case "space":
			document.showLogin.entry.value = "space";
			titleName = "空间";
			break;
		case "bar":
			document.showLogin.entry.value = "tieba";
			titleName = "贴吧";
			break;
		case "bbs":
			document.showLogin.entry.value = "forum";
			titleName = "论坛";
			break;
		case "login":
			document.showLogin.entry.value = "sso";
			titleName = "会员中心";
			break;
	};
	sina.$("loginFldselectdis").innerHTML = titleName;
	sina.writeCookie("loginType",title,2160,"sina.com.cn;path=/");
	if(document.showLogin.username.value != "" && document.showLogin.password.value != ""){
		document.showLogin.onsubmit();
	};
	LoginSelectClose();
};
function openLoginType(){
	if(document.showLogin.username.value != "" && document.showLogin.username.value.indexOf("@") == -1 && sina.$("loginFldselectdis").innerHTML == "选择去向"){
		sina.$("loginFldselectop").style.display = "block";
		sina.addEvent(document.body,"mousedown",LoginSelectClickOther);
	}
}















function GetObj(objName){if(document.getElementById){return eval('document.getElementById("'+objName+'")')}else if(document.layers){return eval("document.layers['"+objName+"']")}else{return eval('document.all.'+objName)}}
/* GetObj end */

/* 显示/隐藏一个容器 begin */
function hiddenObj(ObjId){GetObj(ObjId).style.display="none"}function showObj(ObjId){GetObj(ObjId).style.display="block"}
/* 显示/隐藏一个容器 end */

/* 改变className begin */
function chgClassName(ObjId,className){GetObj(ObjId).className=className}
/* 改变className end */

function showTime(){var date=new Date();var year=date.getYear();year=(year<2008)?(year+1900):year;var month=date.getMonth()+1;var day=date.getDate();var time=year+"."+month+"."+day;return time;}

/* ========== 舌签构造函数 begin ========== */
/* 081104001 ws begin */
/*
舌签构造函数
SubShowClass(ID[,eventType][,defaultID][,openClassName][,closeClassName])
version 1.30
*/
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('m 6(a,b,c,d,e){5.u=6.$(a);7(5.u==k&&a!="n"){M y N("6(p)参数错误:p 对像存在!(Z:"+a+")")};7(!6.q){6.q=y 1r()};5.p=6.q.9;6.q.1d(5);5.1s=r;5.8=[];5.10=c==k?0:c;5.E=5.10;5.11=d==k?"1t":d;5.13=e==k?"":e;5.F=r;j f=P("6.q["+5.p+"].F = z");j g=P("6.q["+5.p+"].F = r");7(a!="n"){7(5.u.v){5.u.v("14",f)}w{5.u.Q("15",f,r)}};7(a!="n"){7(5.u.v){5.u.v("16",g)}w{5.u.Q("17",g,r)}};7(18(b)!="1u"){b="1v"};b=b.1w();1x(b){U"14":5.B="15";G;U"16":5.B="17";G;U"1y":5.B="1z";G;U"1A":5.B="1B";G;1C:5.B="1D"};5.H=r;5.A=k;5.R=1E};6.t.1F="1.1G";6.t.1H="1I";6.t.1e=m(a,b,c,d,e){7(6.$(a)==k&&a!="n"){M y N("1e(1f)参数错误:1f 对像存在!(Z:"+a+")")};j f=5.8.9;7(c==""){c=k};5.8.1d([a,b,c,d,e]);j g=P(\'6.q[\'+5.p+\'].C(\'+f+\')\');7(a!="n"){7(6.$(a).v){6.$(a).v("1J"+5.B,g)}w{6.$(a).Q(5.B,g,r)}};7(f==5.10){7(a!="n"){6.$(a).V=5.11};7(6.$(b)){6.$(b).J.W=""};7(5.p!="n"){7(c!=k){5.u.J.1g=c}};7(d!=k){S(d)}}w{7(a!="n"){6.$(a).V=5.13};7(6.$(b)){6.$(b).J.W="n"}};j h=P("6.q["+5.p+"].F = z");j i=P("6.q["+5.p+"].F = r");7(6.$(b)){7(6.$(b).v){6.$(b).v("14",h)}w{6.$(b).Q("15",h,r)};7(6.$(b).v){6.$(b).v("16",i)}w{6.$(b).Q("17",i,r)}}};6.t.C=m(a,b){7(18(a)!="19"){M y N("C(1h)参数错误:1h 不是 19 类型!(Z:"+a+")")};7(b!=z&&5.E==a){K};j i;T(i=0;i<5.8.9;i++){7(i==a){7(5.8[i][0]!="n"){6.$(5.8[i][0]).V=5.11};7(6.$(5.8[i][1])){6.$(5.8[i][1]).J.W=""};7(5.p!="n"){7(5.8[i][2]!=k){5.u.J.1g=5.8[i][2]}};7(5.8[i][3]!=k){S(5.8[i][3])}}w 7(5.E==i||b==z){7(5.8[i][0]!="n"){6.$(5.8[i][0]).V=5.13};7(6.$(5.8[i][1])){6.$(5.8[i][1]).J.W="n"};7(5.8[i][4]!=k){S(5.8[i][4])}}};5.E=a};6.t.1a=m(){7(s.9!=5.8.9){M y N("1a()参数错误:参数数量与标签数量不符!(9:"+s.9+")")};j a=0,i;T(i=0;i<s.9;i++){a+=s[i]};j b=1K.1a(),1b=0;T(i=0;i<s.9;i++){1b+=s[i]/a;7(b<1b){5.C(i);G}}};6.t.1i=m(){7(s.9!=5.8.9){M y N("1i()参数错误:参数数量与标签数量不符!(9:"+s.9+")")};7(!(/^\\d+$/).1j(6.D)){K};j a=0,i;T(i=0;i<s.9;i++){a+=s[i]};j b=6.D%a;7(b==0){b=a};j c=0;T(i=0;i<s.9;i++){c+=s[i];7(c>=b){5.C(i);G}}};6.t.1L=m(a){7(18(a)=="19"){5.R=a};X(5.A);5.A=1c("6.q["+5.p+"].Y()",5.R);5.H=z};6.t.Y=m(){7(5.H==r||5.F==z){K};5.1k()};6.t.1k=m(){j a=5.E;a++;7(a>=5.8.9){a=0};5.C(a);7(5.H==z){X(5.A);5.A=1c("6.q["+5.p+"].Y()",5.R)}};6.t.1M=m(){j a=5.E;a--;7(a<0){a=5.8.9-1};5.C(a);7(5.H==z){X(5.A);5.A=1c("6.q["+5.p+"].Y()",5.R)}};6.t.1N=m(){X(5.A);5.H=r};6.$=m(a){7(x.1l){K S(\'x.1l("\'+a+\'")\')}w{K S(\'x.1O.\'+a)}};6.1m=m(l){j i="",I=l+"=";7(x.L.9>0){j a=x.L.1n(I);7(a!=-1){a+=I.9;j b=x.L.1n(";",a);7(b==-1)b=x.L.9;i=1P(x.L.1Q(a,b))}};K i},6.1o=m(O,o,l,I){j i="",c="";7(l!=k){i=y 1p((y 1p).1R()+l*1S);i="; 1T="+i.1U()};7(I!=k){c=";1V="+I};x.L=O+"="+1W(o)+i+c};6.D=6.1m("1q");7((/^\\d+$/).1j(6.D)){6.D++}w{6.D=1};6.1o("1q",6.D,12);',62,121,'|||||this|SubShowClass|if|label|length||||||||||var|null||function|none||ID|childs|false|arguments|prototype|parentObj|attachEvent|else|document|new|true|autoPlayTimeObj|eventType|select|sum|selectedIndex|mouseIn|break|autoPlay||style|return|cookie|throw|Error||Function|addEventListener|spaceTime|eval|for|case|className|display|clearInterval|autoPlayFunc|value|defaultID|openClassName||closeClassName|onmouseover|mouseover|onmouseout|mouseout|typeof|number|random|percent|setInterval|push|addLabel|labelID|background|num|order|test|nextLabel|getElementById|readCookie|indexOf|writeCookie|Date|SSCSum|Array|lock|selected|string|onmousedown|toLowerCase|switch|onclick|click|onmouseup|mouseup|default|mousedown|5000|version|30|author|mengjia|on|Math|play|previousLabel|stop|all|unescape|substring|getTime|3600000|expires|toGMTString|domain|escape'.split('|'),0,{}))
/* 081104001 ws end */

/* ========== 舌签构造函数 end ========== */
try{document.execCommand('BackgroundImageCache', false, true);}catch(e){}











eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('11 1a=1b 1K();1a.2c=(1t 1c.1L!=\'1u\')&&(1t 1c.1L.2d!=\'1u\')&&(1t 2e!=\'1u\');1a.2f=16.1j?15:1k;1a.1M=(1N.1O.1P().19("2g")!=-1);1a.2h=(1N.1O.1P().19("2i")!=-1);10(1a.1M){1Q()}13 1Q(){1v.1w.1x("2j",13(){11 a=12.1y;1l(a.1z!=1)a=a.17;14 a});1v.1w.1x("1R",13(){11 a;10(12.1m=="1S")a=12.1T;18 10(12.1m=="1U")a=12.1y;10(!a)14;1l(a.1z!=1)a=a.17;14 a});1v.1w.1x("1V",13(){11 a;10(12.1m=="1U")a=12.1T;18 10(12.1m=="1S")a=12.1y;10(!a)14;1l(a.1z!=1)a=a.17;14 a})}13 1A(a,b){1l(a!=1d){a=a.17;10(a==b)14 15}14 1k}11 1e=1b 1K();11 1n;11 1B;11 1W=0;13 1C(a,b){10(a.19("1f")!=-1||a.19("1D")!=-1)a=a.1X(6);18 10(a.19("2k")!=-1)a=a.1X(4);18 a="";14 b+a}13 2l(){1E(11 i=0;i<1Y.1F;i++){11 d=1c.1G(1Y[i]);1o=d.1H("2m");1E(11 j=0;j<1o.1F;j++){11 e=1o[j];10(e.17.17!=d)2n;11 f=e.1H("a")[0];11 g=f.1p("1Z");11 h=f.1p("20");e.1g=13(a){10(a){12.1h="1f";12.1q=1C(12.1q,"1f")}18{12.1h="1D";12.1q=1C(12.1q,"1D")}};e.21=13(){12.1g(15);12.17.17.1i.1g(1k);12.17.17.1i=12;11 a=12.1H("a")[0];22(a.1p("1Z"),a.1p("20"))};e.2o=13(a){11 b=16.1r?16.1r:a;11 c=b.1R;10(1A(c,12)||c==12)14;10(12.1h=="1f")14;1B=12;23(1n);1n=16.2p("1B.21();",1W)};e.2q=13(a){11 b=16.1r?16.1r:a;11 c=b.1V;10(1A(c,12)||c==12)14;10(12.1h=="1f")14;23(1n)};10(g.19("#2r")!=-1){e.1g(15);d.1i=e;1e[g]=1I(h).1s}18{e.1g(1k)}}10(d.1i==1d)d.1i=1o[0]}}13 24(){11 a;10(16.1J){a=1b 1J();10(a.25){a.25("2s/2t")}}18 10(16.1j){26{a=1b 1j("2u.27")}28(e){26{a=1b 1j("2v.27")}28(e){}}}10(!a){16.2w("2x\'t 2y 1J 2z.");14 1d}14 a}13 29(a,b,c,d){11 e=1b 2A();11 f;11 i;e[0]="";e[1]="A B C D E F G H I J K L M N O P Q R S T U V W X Y Z";e[2]="a b c d e f g h i j k l m n o p q r s t u v w x y z";e[3]="0 1 2 3 4 5 6 7 8 9";10(!b&&!c&&!d){b=15;c=15;d=15}10(b){e[0]+=e[1]}10(c){e[0]+=" "+e[2]}10(d){e[0]+=" "+e[3]}e[0]=e[0].2B(" ");f="";1E(i=0;i<a;i++){f+=e[0][2a.2C(2a.2D()*(e[0].1F-1))]}14(f)}11 2b=29(2E,15,15,15);13 22(a,b){11 c=1I(b);10(1e[a]==1d){11 d=24();d.2F=13(){10(d.2G==4&&(d.1h==2H||16.2I.2J.19("2K")==-1)){c.1s=d.2L;1e[a]=c.1s}};d.2M("2N",a+"?r="+2b,15);d.2O(1d)}18{c.1s=1e[a]}}16.2P=13(){14 15};13 1I(a){14(1c.1G)?1c.1G(a):1c.2Q[a]}',62,177,'||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||if|var|this|function|return|true|window|parentNode|else|indexOf|Browser|new|document|null|ajccache|active|setActive|status|activetab|ActiveXObject|false|while|type|waitInterval|ulist|getAttribute|className|event|innerHTML|typeof|undefined|Event|prototype|__defineGetter__|target|nodeType|IsChild|tempref|getTBprefixName|normal|for|length|getElementById|getElementsByTagName|getElement|XMLHttpRequest|Object|implementation|isFirefox|navigator|userAgent|toLowerCase|extendEventObject|fromElement|mouseover|relatedTarget|mouseout|toElement|MouseDelayTime|substr|arguments|urn|rel|LoadTab|loadAJAXTab|clearTimeout|getXmlhttp|overrideMimeType|try|XMLHTTP|catch|rnd_str|Math|urlRdm|isMozilla|createDocument|HTMLDocument|isIE|firefox|isOpera|opera|srcElement|over|startajaxtabs|li|continue|onclick|setTimeout|onmouseout|default|text|xml|Msxml2|Microsoft|alert|can|create|object|Array|split|round|random|32|onreadystatechange|readyState|200|location|href|http|responseText|open|GET|send|onerror|all'.split('|'),0,{}))














function newbfring(aid,key,id){
	var ringpre=window.open('http://bf.sina.com.cn/rng/'+aid+'_'+id+'_400.html');
	window.open('http://bf.sina.com.cn/sinarc_php/srchring.php?from=400&aid='+aid+'&key='+key);
	ringpre.focus();
}
function newbfring_t(aid,type,id){
	var ringpre_t=window.open('http://bf.sina.com.cn/rng/'+aid+'_'+id+'_400.html');
	window.open('http://bf.sina.com.cn/sinarc_php/ringlist.php?from=400&aid='+aid+'&type='+type);
	ringpre_t.focus();
}
function newbfpic(type,aid,id){
	var picpre=window.open('http://bf.sina.com.cn/pic/'+aid+'_'+id+'_400.html');
	window.open('http://bf.sina.com.cn/sinarc_php/piclist.php?from=400&aid='+aid+'&type='+type);
	picpre.focus();
}
function newyytype(type) {
	window.open('http://bf.sina.com.cn/sinarc_php/yycqlist.php?from=400&type='+type);}
	function newPlay(id,keyword){
	cl_rbt=window.open('http://cl.sina.com.cn/newplay.php?from=400&id='+id,'play','width=650,height=430,resizable=1,scrollbars=0,status=no,toolbar=no,location=no,menu=no');
	window.open('http://cl.sina.com.cn/newindex_search.php?searchtype=2&from=400&keyword='+keyword);
	cl_rbt.focus();
}











function iask(fn,strName){
        if(fn.k.value=="" || fn.k.value=="请输入关键词"){fn.k.value="请输入关键词";fn.k.focus();return false;}
        if(strName == "blog"){
			if(document.forms["iask_f"].t.selectedIndex==3){
				fn.action="http://q.blog.sina.com.cn/group_search.php";
			} else {
				if(document.forms["iask_f"].t.selectedIndex==2){
					document.getElementById("s").value=0;
					fn.action="http://search.blog.sina.com.cn/blog/search";
				} else {
					fn.action="http://search.blog.sina.com.cn/blog/search";
				}				//fn.action="http://search.blog.sina.com.cn/blog/search";
			}
		} else {
			return false;
		}
        fn.submit();
        return false;
}
function g(URL){window.location.href=URL;}



function recordHotPv(a,hwfrom,tag,keyword){
	try{
		new Image().src = "http://mark.sina.com.cn/v2/hot_pv.php?keyword="+keyword+"&hwfrom="+hwfrom+"&tag="+tag+"&_d="+(new Date()).getTime()+"&url="+a.href;
	}catch(ex){
	}
	return true;
}
function recordBlogHotPv(a,hwfrom){
	try{
		new Image().src = "http://mark.sina.com.cn/v2/blog_hot_pv.php?keyword="+a.innerHTML+"&hwfrom="+hwfrom+"&tag=4&_d="+(new Date()).getTime()+"&url="+a.href;
	}catch(ex){
	}
	return true;
}

function recordSinaHotPv(a,hwfrom,keyword){
	try{
		if (typeof(keyword) == "undefined")
		{
			keyword = a.innerHTML;
		}
		new Image().src = "http://mark.sina.com.cn/v2/hot_pv.php?keyword="+keyword+"&hwfrom="+hwfrom+"&tag=5&_d="+(new Date()).getTime()+"&url="+a.href;
	}catch(ex){
	}
	return true;
}





