ajax三种发送方式demo
Posted zhz-8919
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了ajax三种发送方式demo相关的知识,希望对你有一定的参考价值。
.ajax方法:
$.ajax( url:"$pageContext.request.contextPath/user/checkUserName", data:"username":username, type:"post", dataType:"json", success:function (data) alert(data); );
.post方法
$.post(
"$pageContext.request.contextPath/user/isUniqueUsername", //url
"username":username, //data
function(data), //success
'text' //dataType
);
以上是关于ajax三种发送方式demo的主要内容,如果未能解决你的问题,请参考以下文章