<head>  
<title>Ajax with jQuery Example</title>  
<script type="text/JavaScript" src="jquery-1.3.2.min.js"></script>  
<script type="text/JavaScript">  
$(document).ready(
function(){  
    $(
"#generate").click(function(){  
      $(
"#quote p").load("script.html");  
    });  
});  

</script>  
<style type="text/css">  
    #wrapper {  
      width: 240px;  
      height: 80px;  
      margin: auto;  
      padding: 10px;  
      margin
-top: 10px;  
      border: 1px solid black;  
      text
-align: center;  
    }  
</style>  
</head>  
<body>  

<div id="wrapper">  
    
<div id="quote"><p> </p></div>  
    
<input type="submit" id="generate" value="Generate!">  
</div>  
</body>  
</html>

 

作者:ret00100
本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-05-25
  • 2021-12-20
  • 2022-12-23
  • 2022-02-21
  • 2022-12-23
猜你喜欢
  • 2021-05-08
  • 2021-07-01
  • 2021-12-28
  • 2022-12-23
  • 2021-11-26
  • 2021-12-18
相关资源
相似解决方案