AJAX请求(JQuery)

mac2024-10-06  46

$.ajax({ url:page, data:{"name":value}, success:function(result){ $("#checkResult").html(result); } }); $.get( page, {"name":value}, function(result){ $("#checkResult").html(result); } );//专门发送GET请求 $.post( page, {"name":value}, function(result){ $("#checkResult").html(result); } /*$("#id").load(page,[data]);*/ $("#checkResult").load(page,{"name":value}); //最简单 <div id="checkResult"></div> <p>输入账号:<input id="name" type="text"></p> <script src="JQuery.js"></script> <script> $(function(){ $("#name").keyup(function(){ var value=$(this).val(); var page="...checkName.jsp?"; </script>
最新回复(0)