摘要:
$(function() { $("#Button1").click(function() { //无参数 $.ajax({ type: "post", //访问WebService使用Post方式请求 contentType: "application/json", //WebService 会返回Json类型 url: "WebService.asmx/HelloWorld", //调用WebService的地址和方法名称组合 data: "{}", //这里是要传递的参数,格式为 data 阅读全文