function goSetDate(threadid){
    if (document.getElementById("span_"+threadid).style.display=="none"){
        $("#span_"+threadid).slideDown();
    }else{
        $("#span_"+threadid).slideUp();
    }
}    
function setDate(threadid,postorthread){
    if (postorthread == ""){
        postorthread = "thread"
    }
    $.ajax({
        type: "POST",
        url: "changedate.php",
        data: ({type: postorthread
              ,day: $("#t_day_"+threadid).val()
              ,month: $("#t_month_"+threadid).val()
              ,year: $("#t_year_"+threadid).val()
              ,secound: $("#t_secound_"+threadid).val()
              ,minute: $("#t_minute_"+threadid).val()
              ,houre: $("#t_houre_"+threadid).val()
              ,id: threadid}),
        success : function(messaget){
            $("#span_"+threadid).html(messaget);
            setTimeout("refreshpage()",2000);
        }
    });
    return false;
}
function refreshpage(){
    location.reload();
}
