<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>http://jackxiang.com/index.php</link> 
<description><![CDATA[赢在IT，Playin' with IT,Focus on Killer Application,Marketing Meets Technology.]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></copyright>
<item>
<link>http://jackxiang.com/post//</link>
<title><![CDATA[[ajax学习]ajax异步调用函数]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[WEB2.0]]></category>
<pubDate>Thu, 27 Sep 2007 04:43:18 +0000</pubDate> 
<guid>http://jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	<script type="text/javascript" language="javascript"><br/>&nbsp;&nbsp;var http_request=false;<br/> &nbsp;function send_request(url)&#123;//初始化，指定处理函数，发送请求的函数<br/> &nbsp; &nbsp;http_request=false;<br/> &nbsp; &nbsp;<br/>//开始初始化XMLHttpRequest对象<br/> if(window.XMLHttpRequest)&#123;//Mozilla浏览器<br/>&nbsp;&nbsp; &nbsp;http_request=new XMLHttpRequest();<br/>&nbsp;&nbsp; &nbsp;if(http_request.overrideMimeType)&#123;//设置MIME类别<br/>&nbsp;&nbsp; &nbsp; &nbsp;http_request.overrideMimeType("text/xml");<br/>&nbsp;&nbsp; &nbsp;&#125;<br/>&#125;<br/>else if(window.ActiveXObject)&#123;//IE浏览器<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;try&#123;<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; http_request=new ActiveXObject("Msxml2.XMLHttp");<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&#125;catch(e)&#123;<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; try&#123;<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; http_request=new ActiveXobject("Microsoft.XMLHttp");<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp; &#125;catch(e)&#123;&#125;<br/>&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&#125;<br/> &nbsp; &nbsp;&#125;<br/>&nbsp;&nbsp;&nbsp;&nbsp;if(!http_request)&#123;//异常，创建对象实例失败<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;window.alert("创建XMLHttp对象失败！");<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;return false;<br/>&nbsp;&nbsp;&nbsp;&nbsp;&#125;<br/>&nbsp;&nbsp;http_request.onreadystatechange=processrequest;<br/>&nbsp;&nbsp;//确定发送请求方式，URL，及是否同步执行下段代码<br/> &nbsp; &nbsp;http_request.open("GET",url,true);<br/> &nbsp; &nbsp;alert(url);<br/>&nbsp;&nbsp;http_request.send(null);<br/>&nbsp;&nbsp;<br/> &nbsp;&#125;<br/> &nbsp;//处理返回信息的函数<br/> &nbsp; function processrequest()&#123;<br/> &nbsp; if(http_request.readyState==4)&#123;//判断对象状态<br/> &nbsp; &nbsp; if(http_request.status==200)&#123;//信息已成功返回，开始处理信息<br/> &nbsp; //页面显示正在发送数据<br/> &nbsp;&#125;<br/> &nbsp;else&#123;//页面不正常<br/> &nbsp; &nbsp;alert("您所请求的页面不正常！");<br/> &nbsp;&#125;<br/> &nbsp; &#125;<br/> &nbsp;&#125;<br/>&nbsp;&nbsp; &nbsp; &nbsp;function commitReview()&#123;<br/>&nbsp;&nbsp;&nbsp;&nbsp;var artid = document.getElementById("artid").value;<br/>&nbsp;&nbsp;&nbsp;&nbsp;var rev_content = document.getElementById("revcontent").value;<br/>&nbsp;&nbsp;&nbsp;&nbsp;var reviewer = document.getElementById("reviewer").value;<br/>&nbsp;&nbsp;&nbsp;&nbsp;var ip = document.getElementById("ip").value;<br/>&nbsp;&nbsp;&nbsp;&nbsp;if (artid == "" &#124;&#124; rev_content == "")<br/>&nbsp;&nbsp;&nbsp;&nbsp;&#123;<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;alert("你没有填写评论内容！");<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br/>&nbsp;&nbsp;&nbsp;&nbsp;&#125;&nbsp;&nbsp;<br/>&nbsp;&nbsp;&nbsp;&nbsp;var baseUrl = "BlogServlet.jsp?";<br/>&nbsp;&nbsp;&nbsp;&nbsp;var url = baseUrl + "artid=" + artid + "&revcontent=" + rev_content + "&reviewer=" + reviewer + "&ip" + ip;<br/>&nbsp;&nbsp;&nbsp;&nbsp;send_request(url);<br/>&nbsp;&nbsp;&nbsp;&nbsp;&#125;<br/></script>
]]>
</description>
</item><item>
<link>http://jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [ajax学习]ajax异步调用函数]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>