	function d_reply(t, tid, id, cur_page)
	{
		$.get('/inc/ajax.php', {type:9, t:t, id:id}, function(rs){	
			if(rs=='yes')
			{
				reloadReply(t, tid, cur_page)
				//location.reload();
			}
		});
	}
	function reloadReply(t, id, cur_page)
	{
		if(cur_page=='') cur_page=1;
		$.get('/inc/ajax.php', {type:2, t:t, id:id, curpage:cur_page}, function(rs){	
			$("#replylist").html(rs);
		});
	}
	function doSearch(key, t)
	{
		var k = encodeURI($("#"+key).val());
		location='/index.php?do=search&amp;key='+k+'&type='+t;
	}
	function do_login()
	{
		var msg = 'تىزىملىتىپ كىرىپ مەشخۇلات قىلىشىڭىزنى تەۋىسسيە قىلىمىز!';
		var msg2 = '<form method="post" action="" name="form2" onsubmit="return CheckLogin()"><ul class="loginbox"><li><span>ئىسىم:</span><input type="text" class="ltr" id="name" name="name"  /></li><li><span>پارۇل:</span><input type="password" class="ltr" id="pass" name="pass" /></li><li><input class="login_btn" type="submit" value="كــىرىش" /> | <a class="reg_btn" href="/user/reg.php" target="_blank">تىزىملىتىمەن</a> | <a class="reg_btn" href="/user/reg.php?dopost=pass" target="_blank">پارۇل ئۇنتۇلغان؟</a> </li></ul></form>';
		jAlert(msg + msg2);
	}
	function do_favourite(t, id)
	{
		$.get('/user/user_ajax.php?type=15&t='+t+'&aid='+id, {}, function(rs){jAlert(rs)});
		return false;
	}
	function jubao_video(id, t)
	{
		var html = 'مەسىلە مەلۇم قىلغاندا ئەستايىدىل بولۇڭ، ھەم مەزمۇندا بۇ فىلىمدا ساقلانغان مەسىلىنىڭ خاراكىتىرىنى ئىنىق ئەسكەرتىڭ. مۇناسىۋەتلىك ئۇچۇرلىڭىز خاتىرلىنىدۇ.<br /><textarea id="jubao_body" rows="3" cols="40" onkeypress="naddchar()"></textarea><br /><input type="button" value="مەزمۇننى يوللاش" onclick="do_jubao('+id+', 1)" />';
		jAlert(html);
		return false;
	}
	function do_jubao(id, t)
	{
		var body = $("#jubao_body").html();
		$.post('/inc/ajax.php', {type:16, t:t, aid:id, body:body}, function(){
			jAlert('مۇۋاپىقىيەتلىك بولدى، رەھمەت سىزگە!');
		});
	}
	function do_search2()
	{
		var key1 = $("#key2").val();
		if(key1=='' || key1=='ئىسمىنى كىرگۈزۈڭ')
		{
			jAlert('نىمىنى ئىزدىمەكچىتىڭىز؟');
			return false;
		}
		var url = '/index.php?do=member&act=search&name='+encodeURI(key1)+'&sex=-1&city3=0&city4=0&city=0&city2=0&school=0&type=-1';
		location=url;
	}
	function replay_html()
	{
		$.get('/inc/ajax.php?type=15', {}, function(rs){
				alert(rs);
				$("#replay_html").html(rs);
			})
	}
	$(function(){
		 $("#go_login").click(function(){
				do_login();
				return false;
			 });
	})
function getcookie(name) {
var cookie_start = document.cookie.indexOf(name);
var cookie_end = document.cookie.indexOf(";", cookie_start);
return cookie_start == -1 ? '' : unescape(document.cookie.substring(cookie_start + name.length + 1, (cookie_end > cookie_start ? cookie_end : document.cookie.length)));
}
function setcookie(cookieName, cookieValue, seconds, path, domain, secure) {
var expires = new Date();
expires.setTime(expires.getTime() + seconds);
document.cookie = escape(cookieName) + '=' + escape(cookieValue)
+ (expires ? '; expires=' + expires.toGMTString() : '')
+ (path ? '; path=' + path : '/')
+ (domain ? '; domain=' + domain : '')
+ (secure ? '; secure' : '');
}

function sh(thisObj,Num){
if(thisObj.className == "active")return;
var tabObj = thisObj.parentNode.id;
var tabList = document.getElementById(tabObj).getElementsByTagName("li");
for(i=0; i <tabList.length; i++)
{
if (i == Num)
{
thisObj.className = "active";
document.getElementById(tabObj+"_"+i).style.display = "block";
}else{
tabList[i].className = "normal";
document.getElementById(tabObj+"_"+i).style.display = "none";
}
}
}

