var userid_0404;
function send_request_userdate(user_id,url) 
{//初始化、指定处理函数、发送请求的函数
   userid_0404=user_id;
   http_request_date = false;
   //开始初始化XMLHttpRequest对象
   if(window.XMLHttpRequest) 
   { //Mozilla 浏览器 
      http_request_date = new XMLHttpRequest();
      if (http_request_date.overrideMimeType) 
	   {//设置MiME类别
        http_request_date.overrideMimeType('text/html');
       }
   }
  else 
    if (window.ActiveXObject) 
	{ // IE浏览器
       try 
	   {
          http_request_date = new ActiveXObject("Msxml2.XMLHTTP");
       } 
	   catch (e) 
	   {
          try 
		   {
               http_request_date = new ActiveXObject("Microsoft.XMLHTTP");
           } catch (e) {}
       }//end catch
   }//end if

if (!http_request_date) { // 异常，创建对象实例失败
window.alert("不能创建XMLHttpRequest对象实例.");
return false;
}


// 确定发送请求的方式和URL以及是否同步执行下段代码
//alert(url);
//get  方式提交
//http_request_date.open("get", url, true);
//http_request_date.send(null);
//post 方式提交
http_request_date.open("post", url, true);
http_request_date.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=utf-8");
//抽出参数
//alert(id);
//alert("userid="+user_id+"&post_title="+$("content")+"&id="+$("id")+"&post_user="+$("user_name")+"&post="+post);
http_request_date.send("userid="+user_id);
http_request_date.onreadystatechange = processRequest_date;

}

//来处理显示结果
function processRequest_date()
{
if(http_request_date.readyState==4)
{
 if(http_request_date.status==200)//请求成功 
 {
 //
  //var note=http_request_date.responseXML.getElementsByTagName("root").item(0);
  ///alert(http_request_date.responseText+"&#13\t"+note.firstChild.data);
    var e,dc_id,content,value;
　　var xmldoc = http_request_date.responseXML;
	var employees = xmldoc.getElementsByTagName("tr_1");
	//写表格的变量
	var row,tb,ff;
	

	ff=0;
	//document.getElementById("userDate_"+userid_0404).innerHTML="qqqq";
	//alert(employees.length);
	for(var i=0;i<employees.length;i++) 
	{
		e = employees[i];
		//alert(e.length);
		//var name = e.getAttribute("name");
		/*
		e.getElementsByTagName("td_1")[0].firstChild.data;
		e.getElementsByTagName("td_2")[0].firstChild.data;
		e.getElementsByTagName("td_3")[0].firstChild.data;
		*/
		//alert(dc_id+"  ==   "+content+"   ==   "+value);
		//对表格1的操作
		/*
		for (var h=document.getElementById("counter1").rows.length-1;h>=0;h--)
        {
			document.getElementById("counter1").deleteRow(h);
        }
        */
		//row=document.getElementById("counter1").insertRow(0); 
        //document.getElementById("counter1").value=document.getElementById("content").value+"&#13----------------------&#13"+document.getElementById("counter1").value;
       // play("/mid/di.wav");
	   //alert(userid_0404);
	  // alert(e.getElementsByTagName("td_1")[0].firstChild.data);
	   //alert(e.getElementsByTagName("td_1")[0].firstChild.data);
	   if(document.getElementById("userDate_"+userid_0404).innerHTML=="加载中..")
	   {
	   
	   document.getElementById("userDate_"+userid_0404).innerHTML=e.getElementsByTagName("td_1")[0].firstChild.data;
	   }
	   
	}
 
 }
 else
 window.status="please check ajax javascript";
 
}//end if

}//end fun
