编辑您的代码:
查看结果:
<html> <head> <script type="text/javascript" src="../jquery/jquery.js"></script> <script type="text/javascript"> $(document).ready(function(){ $("div").ajaxError(function(e,xhr,opt){ alert("Error requesting " + opt.url + ": " + xhr.status + " " + xhr.statusText); }); $("button").click(function(){ $("div").load("wrongfile.txt"); }); }); </script> </head> <body> <div id="txt"><h2>通过 AJAX 改变文本</h2></div> <button>改变内容</button> </body> </html>
查看结果:
系统帮助
|
给我留言
|
收藏本站
Copyright © 2005-2008
www.cnn84.com
All Rights Reserved Ver:2.0
桂公网安备45122402000102号
CNN84网是公益性便民网站,是为了给大家的日常生活查询及提供最快捷的出行指南
晚上好!CNN84祝你今晚玩的愉快!天天都有新收获!