案例:jQuery案例     状态:可编辑再运行    进入竖版
 运行结果 
AخA
 
1
<html>
2
<head>
3
<script type="text/javascript" src="/js/jquery.js"></script>
4
<script type="text/javascript">
5
$(document).ready(function(){
6
  $("input").keyup(function(){
7
    txt=$("input").val();
8
    $("span").load("/example/aspnet/gethint.aspx?q="+txt);
9
  });
10
});
11
</script>
12
</head>
13
<body>
14
<p>请在下面的输入框中输入名字(a 到 z 的字符):</p>
15
名字:<input type="text" />
16
<p>建议:<span></span></p>
17
<p>注释:我们在 <a href="/jsjq/ajax/ajax_asp_php.html" target="_blank">AJAX 教程</a> 中讲解过本例中使用的文件(gethint.aspx)。</p>
18
</body>
19
</html>