document.write("<style>#CB_t .selectLoginSite { z-index:1000}</style>");
document.write("<link href=\"http://image.yesky.com/TLimages/chinabyte/css/headfloor_950_090309.css\" type=\"text/css\" rel=\"stylesheet\" media=\"all\" />");
document.write("<div id=\"__cb_top\"><div id=\"CB_t\"><div class=\"login_sites\" id=\"login_bar\"><div class=\"denglu\"><span class=\"mg_2 index_link\"><a href=\"http://www.chinabyte.com/\">比特首页</a> | </span>");
					function $(id){return document.getElementById(id)}	
					var url = document.location.href;
					var t_loginHTML = "";
					if(customerid!=0)
				   {
					 if(url.indexOf("ticket") > -1) url= url.substring(0,url.indexOf("ticket"));
					 if(url.indexOf("?")==url.length-1) url= url.substring(0,url.indexOf("?"));
					 document.writeln(" <div id=\"t_login_arrow\"><\/div><div class=\"t_logined\">欢迎<a href=\"http://passport.chinabyte.com/jsp/newcb/cbsys_pass.jsp\"><b><font color=\"#005a98\">"+nickname+"<\/font><\/b><\/a> (<a href=\"javascript:void(0)\" id=\"t_open_link\" class=\"t_mycb_close\" onclick=\"t_hideMyCB()\" target=\"_self\">收起<\/a>) 登录！　<a href=\"http://passport.chinabyte.com/cas/logout?service="+url+"\" target=\"_self\">退出登录<\/a><\/div>");
				   }else{
					t_loginHTML += "<form action=\"http:\/\/passport.chinabyte.com\/cas\/login?service=http:\/\/passport.chinabyte.com\/jsp\/newcb\/cbsys_index.jsp\" name=\"cb_top_login\" method=\"post\" id=\"login_form\" target=\"_blank\" onsubmit=\"window.location.reload();return true;\">";
t_loginHTML += "                    <span class=\"mg_2\">用户名<\/span><input type=\"text\" name=\"username\" class=\"cb_top_input mg_1\"\/>";
t_loginHTML += "                    <span class=\"mg_2\">　密码<\/span><input type=\"password\" name=\"password\" class=\"cb_top_input mg_1\"\/>";
t_loginHTML += "                    <div class=\"selectLoginSite\">";
t_loginHTML += "                    	<div class=\"loginSiteName\" id=\"loginSiteName\">通行证<\/div>";
t_loginHTML += "                        <div class=\"selectLoginSiteBtn\" onclick=\"showlayer(\'loginSiteNameList\')\" id=\"selectLoginSiteBtn\" ><\/div>";
t_loginHTML += "                        <ul class=\"loginSiteNameList\" id=\"loginSiteNameList\">";
t_loginHTML += "                        	<li><span rel=\"http:\/\/blog.chinabyte.com\/\" name=\"博客\"><a href=\"javascript:void(0)\" target=\"_self\">博客<\/a><\/span><\/li>";
t_loginHTML += "                            <li><span rel=\"http:\/\/bbs.chinabyte.com\/\" name=\"论坛\"><a href=\"javascript:void(0)\" target=\"_self\" >论坛<\/a><\/span><\/li>";
t_loginHTML += "                            <li><span rel=\"http:\/\/com.chinabyte.com\/\" name=\"企业专区\"><a href=\"javascript:void(0)\" target=\"_self\">企业专区<\/a><\/span><\/li>";
t_loginHTML += "                            <li><span rel=\"http:\/\/bang.chinabyte.com\/\" name=\"比特邦\"><a href=\"javascript:void(0)\" target=\"_self\">比特邦<\/a><\/span><\/li>";
t_loginHTML += "                            <li><span rel=\"http:\/\/passport.chinabyte.com\/jsp\/newcb\/cbsys_index.jsp\" name=\"通行证\"><a href=\"javascript:void(0)\" target=\"_self\">通行证<\/a><\/span><\/li>";
t_loginHTML += "                        <\/ul>";
t_loginHTML += "                    <\/div>";
t_loginHTML += "                    <input type=\"submit\" class=\"cb_top_submit mg_1\" value=\"登录\"\/>";
t_loginHTML += "                    <input name=\"type\" type=\"hidden\" value=\"1\">";
t_loginHTML += "                    <span class=\"mg_2\">&nbsp;<a href=\"http:\/\/passport.chinabyte.com\/jsp\/newcb\/cbsys_login_i.jsp\">新用户注册<\/a><\/span>";
t_loginHTML += "                <\/form>";
					document.write(t_loginHTML);
					var login_form = $("login_form");
					var t_sel_loginSie_spans = $("loginSiteNameList").getElementsByTagName("span");
					var t_sel_loginSie_spans_length = t_sel_loginSie_spans.length;
					for(var i = 0;i<t_sel_loginSie_spans_length;i++){
						t_sel_loginSie_spans[i].onmousedown = function(){$("loginSiteName").innerHTML = this.getAttribute("name");
																		relValue = this.getAttribute("rel");
																		login_form.setAttribute("action","http://passport.chinabyte.com\/cas\/login?service=" + relValue);
																		hidelayer('loginSiteNameList');
																		};
									}
					}
           document.write("</div><div class=\"t_article_search\"><form name=\"search\"  action=\"http://search.chinabyte.com/search.do\" target=\"_blank\"  id=\"top_search\"><input type=\"text\" name=\"wd\" class=\"cb_top_aritcleSearch_input mg_1\" /><input type=\"submit\" class=\"cb_top_aritcleSearch_submit mg_1\" value=\"比特搜索\" /></form></div></div><div class=\"t_divLine\"></div>");
        document.write("<div class=\"t_menu_wrapper\"><div id=\"myCbWrapper\" style=\"height:0px;overflow:hidden\"><div class=\"t_mychinabyte\" id=\"t_mychinabyte\"><div class=\"t_close_mychinabyte\" onmousedown=\"t_hideMyCB()\"></div><div class=\"t_my_info\"><b>欢迎来到比特网</b></div><div class=\"t_my_func\"><b>去往：</b><a href=\"http://bbs.chinabyte.com/\" target=\"_blank\"><b>比特论坛</b></a>&nbsp;&nbsp;<span>|</span>&nbsp;&nbsp;<a href=\"http://bang.chinabyte.com/\" target=\"_blank\"><b>比特邦</b></a>　<b>快捷工具：</b><a href=\"http://bang.chinabyte.com/home-space-uid-96463-do-doing-view-all.html\" class=\"t_miniblog\">记录</a><span>|</span><a href=\"http://bang.chinabyte.com/group-my.html\"  class=\"t_blog\">圈子</a><span>|</span><a href=\"http://bang.chinabyte.com/plugin.php?id=cb_documents:mylist\" class=\"t_album\">文档分享</a><span>|</span><a href=\"http://bang.chinabyte.com/home-space-do-blog.html\" class=\"t_share\">日志</a><span>|</span><a href=\"http://http://bang.chinabyte.com/home-space-do-activity.html\" class=\"t_group\">活动</a></div><div class=\"fr pdt7\"><a href=\"http://bang.chinabyte.com/\">进入个人主页&gt;&gt;&nbsp;&nbsp;</a></div></div></div>");

		var myCbWrapper = $("myCbWrapper");
		var t_open_link = $("t_open_link");
		var t_login_arrow = $("t_login_arrow");
		if(customerid!=0){
			myCbWrapper.style.height = "50px";
			$("t_mychinabyte").style.display = "block"
		}
		var t_MyCBInterval = null;
		function t_showMyCB(){
			clearInterval(t_MyCBInterval);
			if(parseInt(myCbWrapper.style.height) <= 0) myCbWrapper.style.height = "0px";
			if(parseInt(myCbWrapper.style.height) < 50) t_MyCBInterval = setInterval("t_heightAdd()",5);
			t_open_link.className = "t_mycb_close";
			t_open_link.onclick = t_hideMyCB;
			t_open_link.innerHTML = "收起";
		}
		function t_hideMyCB(){
			clearInterval(t_MyCBInterval);
			if(parseInt(myCbWrapper.style.height) > 0) t_MyCBInterval = setInterval("t_heightLess()",5);
			t_open_link.className = "t_mycb_open";
			t_open_link.onclick = t_showMyCB;
			t_open_link.innerHTML = "展开";
		}
		function t_heightAdd(){
			myCbWrapper.style.height = parseInt(myCbWrapper.style.height) + 5 +"px";
			if(parseInt(myCbWrapper.style.height) >= 50) { clearInterval(t_MyCBInterval); t_login_arrow.style.backgroundPosition = "-168px -27px"; }
		}
		function t_heightLess(){
			myCbWrapper.style.height = parseInt(myCbWrapper.style.height) - 5 +"px";
			if(parseInt(myCbWrapper.style.height) <= 0) {clearInterval(t_MyCBInterval); t_login_arrow.style.backgroundPosition = "-166px -48px"; }
		}

/* 浮动层显示及隐藏 */
var index = new Object();
index.openlayer = null;//记录页面内已显示层的id
document.onmousedown = function(){
	if (index.openlayer != null) $(index.openlayer).style.display = "none";
	index.openlayer = null;
}

function showSub(id){
	$(id).style.display = "block";
}
function hideSub(id){
	$(id).style.display = "none";
}
function stopBubble(e){
	if(e && e.stopPropagation){
		e.stopPropagation();
	}else{
		window.event.cancelBubble = true;
	}
}
/* 显示层并向全局注册 */
function showlayer(id){
	showSub(id);
	if(index.openlayer != null && index.openlayer != id) hidelayer(index.openlayer);
	index.openlayer = id;
	$(id).onmousedown = function(e){
		stopBubble(e);
	}
}
function hidelayer(id){
	hideSub(id);
	index.openlayer = null;
	$(id).onmousedown = null;
}
     	document.write("<div class=\"t_menu_column_1\"><div class=\"t_menu\"><div class=\"tmA\"><ul class=\"up\"><li><b><a href=\"http://news.chinabyte.com/\">新闻</a></b></li><li><a href=\"http://it.chinabyte.com/\">业界</a></li><li><a href=\"http://telecom.chinabyte.com/\">通信</a></li><li><a href=\"http://net.chinabyte.com/\">互联网</a></li></ul><ul><li class=\"b2\"><a href=\"http://column.chinabyte.com/\">评论</a></li><li><a href=\"http://www.chinabyte.com/video/\">视频</a></li><li><a href=\"http://hea.chinabyte.com/\">家电</a></li><li><a href=\"http://www.chinabyte.com/ztzh/\">专　题</a></li></ul></div><div class=\"tmB\"><ul class=\"up\"><li><b><a href=\"http://e.chinabyte.com/\">企业采购</a></b></li><li ><a href=\"http://server.chinabyte.com/\">服务器</a></li><li><a href=\"http://nbpc.chinabyte.com/\">商用电脑</a></li><li class=\"lir11\"><a href=\"http://network.chinabyte.com/\">网络</a></li><li><a href=\"http://storage.chinabyte.com/\">存储</a></li></ul><ul><li class=\"b4\"><a href=\"http://datacenter.chinabyte.com/\">数据中心</a></li><li class=\"fontArial\"><a href=\"http://oa.chinabyte.com/\">OA办公</a></li><li class=\"b5\"><a href=\"http://sec.chinabyte.com/\">信息安全</a></li><li><a href=\"http://soft.chinabyte.com/\">软件与服务</a></li></ul></div><div class=\"tmC\"><ul class=\"up\"><li><b><a href=\"http://info.chinabyte.com/\">信息化</a></b></li><li class=\"fontArial\"><a href=\"http://cio.chinabyte.com/\">CIO</a></li></ul><ul><li class=\"b3\"><a href=\"http://do.chinabyte.com/\">行　业</a></li><li class=\"fontArial\"><a href=\"http://smb.chinabyte.com/\">SMB</a></li></ul></div><div class=\"tmD\"><ul class=\"up\"><li><a href=\"http://com.chinabyte.com/\">企业专区</a></li><li><a href=\"http://bbs.chinabyte.com/\">论坛</a></li><li><strong><a href=\"http://bang.chinabyte.com/\">比特邦</a></strong></li><li class=\"fontArial\"><a href=\"http://know.chinabyte.com/\">IT知识库</a></li></ul><ul><li><a href=\"http://data.chinabyte.com/\">市场调查</a></li><li><a href=\"http://blog.chinabyte.com/\">博客</a></li><li class=\"b3\"><a href=\"http://product.chinabyte.com/\">产品库</a></li><li class=\"b6\"><a href=\"http://e.chinabyte.com/leadshow/\">电子杂志</a></li></ul></div></div></div></div></div></div>");

