var
urlJSON =
'<%=ResolveUrl("example.json") %>'
;
$(document).ready(
function
() {
$(
'#btnLoad'
).click(
function
() {
$.ajax({
url: urlJSON,
dataType:
"json"
,
type:
"POST"
,
contentType:
"application/json;charset=utf-8"
,
success: AjaxSucceeded,
error: AjaxFailed
});
});
});
function
AjaxSucceeded(result) {
alert(result.d);
}
function
AjaxFailed(result) {
alert(result.status +
' '
+ result.statusText);
}