function Banner_MouseOver(id)
{
document.getElementById(id).style.display = "block"; 
}
function Banner_Mouseout(id)
{
document.getElementById(id).style.display = "none"; 
}

document.writeln("<style>");
document.writeln(".gnb_menu{height:36px; font-size:12px;color:#cccccc;table-layout:fixed; background: url(http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/top_bg_03.gif); margin:0px;}");
document.writeln(".gnb_menu table { margin:0px;}");
document.writeln(".gnb_menu td {line-height: normal; height: auto;}");
document.writeln(".gnb_menu ul{list-style-type: none; margin-left:20px; padding:0; margin-top:0}");
document.writeln(".gnb_menu li{list-style-type: none;color:#cccccc; float:left; margin-right:5px; padding:0;}");
document.writeln(".gnb_menu a:link{color:#666666;font-size:12px;text-decoration: none;}");
document.writeln(".gnb_menu a:visited{color:#666666;font-size:12px;text-decoration: none;}");
document.writeln(".gnb_menu a:hover{color:#666666;font-size:12px;text-decoration: underline;}");
document.writeln(".gnb_menu img{border:0;}");
document.writeln("#gnb_game_list1{width:116px; margin-left:100px;margin-top:7px; position:absolute; z-index:10000; overflow:hidden; display:none}");
document.writeln("#gnb_game_list1 td{ height:20px;padding-left:5px; line-height:14px}");
document.writeln("#gnb_game_list1 .gnb_game_list_b{width:112px; padding-top:5px; padding-bottom:5px;border:#999999 solid 2px; background:#FFFFFF; }");
document.writeln("#gnb_game_list2{width:116px; margin-left:150px;margin-top:7px; position:absolute; z-index:10000; overflow:hidden; display:none}");
document.writeln("#gnb_game_list2 td{ height:20px;padding-left:5px; line-height:14px}");
document.writeln("#gnb_game_list2 .gnb_game_list_b{width:112px; padding-top:5px; padding-bottom:5px;border:#999999 solid 2px; background:#FFFFFF; }");
document.writeln("#gnb_game_list{width:97px; margin-left:415px;margin-top:7px; position:absolute; z-index:10000; overflow:hidden; display:none;}");
document.writeln("#gnb_game_list td{ height:20px;padding-left:5px; line-height:14px}");
document.writeln(".gnb_game_list_t{height:4px; text-align:center;}");
document.writeln("#gnb_game_list .gnb_game_list_b{width:93px; padding-top:5px; padding-bottom:5px;border:#999999 solid 2px; background:#FFFFFF; }");
document.writeln("input.topbtn { background:url(http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_btn_03.gif); width:51px; height:22px; line-height:22px; cursor:pointer; font-weight:700}");
document.writeln(".blackcolor { color:#444; padding-right:15px}");
document.writeln("<\/style>");
document.writeln("<table width=\"100%\" class=\"gnb_menu\">");
document.writeln("<tr>");
document.writeln("<td>");
document.writeln("<table width=\"980\" border=\"0\" align=\"center\" cellpadding=\"0\" cellspacing=\"0\" style=\"margin:0 auto\">");
document.writeln("<tr>");
document.writeln("<td width=\"10\">");
document.writeln("<div id=\'gnb_game_list1\' onmouseover=\"Banner_MouseOver(\'gnb_game_list1\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list1\')\">");
document.writeln("<div class=\"gnb_game_list_t\"><img src=\"http:\/\/images.tiancity.com\/images\/portal\/listtoparrow.gif\"><\/div>");
document.writeln("<div class=\"gnb_game_list_b\">");
document.writeln("<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo2.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/luoqi.tiancity.com\" target=\"_blank\">洛奇<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo5.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/popkart.tiancity.com\" target=\"_blank\">跑跑卡丁车<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo6.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/csol.tiancity.com\/\" target=\"_blank\">反恐精英Online<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo7.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/cfd.tiancity.com\/\" target=\"_blank\">冲锋岛<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_web.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/web.tiancity.com\/\" target=\"_blank\">网页游戏平台<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_yx.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/yx.tiancity.com\/\" target=\"_blank\">武林英雄<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_sg.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/sg.tiancity.com\/\" target=\"_blank\">热血三国<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_letu.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/letu.tiancity.com\/\" target=\"_blank\">乐土<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_plsm.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/plsm.tiancity.com\/\" target=\"_blank\">盘龙神墓<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<\/table>");
document.writeln("<\/div>");
document.writeln("<\/div>");
document.writeln("<div id=\'gnb_game_list2\' onmouseover=\"Banner_MouseOver(\'gnb_game_list2\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list2\')\">");
document.writeln("<div class=\"gnb_game_list_t\"><img src=\"http:\/\/images.tiancity.com\/images\/portal\/listtoparrow.gif\"><\/div>");
document.writeln("<div class=\"gnb_game_list_b\">");
document.writeln("<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo2.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1001&forumid=7\" target=\"_blank\">洛奇<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo6.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showbbs.aspx\" target=\"_blank\">反恐精英Online<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo7.gif\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1007&forumid=1\" target=\"_blank\">冲锋岛<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_web.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td colspan=\"2\"><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showbbs_wg.aspx\" target=\"_blank\">网页游戏平台<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_yx.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1008&forumid=1\" target=\"_blank\">武林英雄<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_sg.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1012&forumid=1\" target=\"_blank\">热血三国<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_letu.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1013&forumid=1\" target=\"_blank\">乐土<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td>&nbsp;<\/td>");
document.writeln("<td><img src=\"http:\/\/images.tiancity.com\/images\/portal\/logo_plsm.jpg\" width=\"13\" height=\"13\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/bbs.tiancity.com\/Forum\/showforum.aspx?gid=1014&forumid=1\" target=\"_blank\">盘龙神墓<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<\/table>");
document.writeln("<\/div>");
document.writeln("<\/div>");
document.writeln("<div id=\'gnb_game_list\' onmouseover=\"Banner_MouseOver(\'gnb_game_list\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list\')\">");
document.writeln("<div class=\"gnb_game_list_t\"><img src=\"http:\/\/images.tiancity.com\/images\/portal\/listtoparrow.gif\"><\/div>");
document.writeln("<div class=\"gnb_game_list_b\">");
document.writeln("<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">");
document.writeln("<tr>");
document.writeln("<td width=\"10\" align=\"right\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/icon_cirle_03.gif\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/pcbar.tiancity.com\" target=\"_blank\">网吧欢乐行<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<tr>");
document.writeln("<td align=\"right\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/icon_cirle_03.gif\" border=\"0\"><\/td>");
document.writeln("<td><a href=\"http:\/\/iga.tiancity.com\/\" target=\"_blank\">商务合作<\/a><\/td>");
document.writeln("<\/tr>");
document.writeln("<\/table>");
document.writeln("<\/div>");
document.writeln("<\/div><\/td>");
document.writeln("<td width=\"92\"><a href=\"http:\/\/www.tiancity.com\/\"><img src=\"http:\/\/images.tiancity.com\/images\/portal\/tclogo.gif\" title=\"首页\"><\/a><\/td>");
document.writeln("<td width=\"437\">");
document.writeln("<ul>");
document.writeln("<li onmouseover=\"Banner_MouseOver(\'gnb_game_list1\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list1\')\"><a href=\"#\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_03.gif\" title=\"游戏\" \/><\/a><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<li onmouseover=\"Banner_MouseOver(\'gnb_game_list2\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list2\')\"><a href=\"http:\/\/bbs.tiancity.com\" target=\"_blank\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_05_.gif\" title=\"广场\" \/><\/a><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<li><a href=\"http:\/\/shop.tiancity.com\/Homepage\/Index.aspx\" target=\"_blank\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_07.gif\" title=\"商城\" \/><\/a><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<li><a href=\"http:\/\/www.tiancity.com\/webphp\/netbarregister\/pointcard\/pointcard.php\" target=\"_blank\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_09.gif\" title=\"购卡\/充值\" \/><\/a><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<li><a href=\"http:\/\/service.tiancity.com\/homepage\/default.asp\" target=\"_blank\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_11.gif\" title=\"客服中心\" \/><\/a><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<li onmouseover=\"Banner_MouseOver(\'gnb_game_list\')\" onmouseout=\"Banner_Mouseout(\'gnb_game_list\')\"><img src=\"http:\/\/images.tiancity.com\/images\/bbs\/gnb_image\/topNav_word_13.gif\" title=\"商务合作\" style=\" cursor:pointer;\" \/><\/li>");
document.writeln("<li>|<\/li>");
document.writeln("<\/ul><\/td>");
document.writeln("<td align=\"right\"><a href=\"http:\/\/matrix.tiancity.com\/\" target=\"_blank\" style=\"color:#666\">提升您的账号安全<\/a><\/td>");
document.writeln("<\/tr><\/table>");
document.writeln("<\/td>");
document.writeln("<\/tr>");
document.writeln("<\/table>")


function Nethru_getCookieVal(offset)
{
	var endstr = document.cookie.indexOf (";", offset);
	if (endstr == -1)
		endstr = document.cookie.length;
	return unescape(document.cookie.substring(offset, endstr));
}

function Nethru_SetCookie(name, value){
   var argv = Nethru_SetCookie.arguments;
   var argc = Nethru_SetCookie.arguments.length;
   var expires = (2 < argc) ? argv[2] : null;
   var path = (3 < argc) ? argv[3] : null;
   var domain = (4 < argc) ? argv[4] : null;
   var secure = (5 < argc) ? argv[5] : false;

  // alert("DOMAIN = " + domain);
   document.cookie = name + "=" + escape (value) +
        ((expires == null) ? "" : ("; expires="+expires.toGMTString())) +
     ((path == null) ? "" : ("; path=" + path)) +
     ((domain == null) ? "" : ("; domain=" + domain)) +
        ((secure == true) ? "; secure" : "");

//	alert(document.cookie);
}

function Nethru_GetCookie(name){
   var arg = name + "=";
   var alen = arg.length;
   var clen = document.cookie.length;
   var i = 0;
   while (i < clen)
      {
      var j = i + alen;
      if (document.cookie.substring(i, j) == arg)
         return Nethru_getCookieVal (j);
      i = document.cookie.indexOf(" ", i) + 1;
      if (i == 0)
         break;
      }
  return null;
}

function Nethru_makePersistentCookie(name,length,path,domain)
{
    var today = new Date();
    var expiredDate = new Date(2011,1,1);
    var cookie;
	var value;

    cookie = Nethru_GetCookie(name);
    if ( cookie ) {
//		alert(cookie);
        return 1;
	}

	var values = new Array();
	for ( i=0; i < length ; i++ ) {
		values[i] = "" + Math.random();
	}

	value = today.getTime();

	// use first decimal
	for ( i=0; i < length ; i++ ) {
		value += values[i].charAt(2);
	}

    Nethru_SetCookie(name,value,expiredDate,path,domain);
}

function Nethru_getDomain() {
	var _host   = document.domain;
	var so      = _host.split('.');
	var dm    = so[so.length-2] + '.' + so[so.length-1];
	return (so[so.length-1].length == 2) ? so[so.length-3] + '.' + dm : dm;
}

var Nethru_domain  = Nethru_getDomain();

Nethru_makePersistentCookie("PCID",10,"/",Nethru_domain);

