1) Add [ScriptService] attribute to your webservice.
2) Call your method with JQuery. Very Simple!
$.ajax({
type: "POST",
url: "ServiceName.asmx/WebMethodName",
data: "{'parameter1':'p1','parameter2':'p2'}",
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function(msg) {
// Do
stuff
}
});
Technorati Tags: Webservices,Jason,JQuery,ASMX,AJAX
No comments:
Post a Comment