日期:2014-05-16 浏览次数:20670 次
<html>
<head>
<script type="text/javascript" src="/jquery/jquery.min.js"></script>
<script type="text/javascript">
$("#a").click(function (){
$('$myDiv').load('/jquery/text1.txt');
});
</script>
</head>
<body>
<div id="myDiv"><h6>ajax将改变这里内容</h6></div>
<button id="a" type="button">ajax将改变下面的内容哦</button>
</body>
</html>
<script type="text/javascript">
$(document).ready(function(){
$("#a").click(function (){
$('$myDiv').load('/jquery/text1.txt');
});
})
</script>