你说的其实就是ajax,而ajax通过jquery会少写很多代码$.get(url,{args1:'',args2:''},function(data){some code...},type)$.post(url,{args:'',args2:''}function(data){some code...},type)url就是你的php文件的url地址,function(data){}中的data是从php返回的数据,那么这个函数就是对得到的数据的处理,一般就是用jquery的.html()方法设置你的DOM内容,type就是返回的数据类型,默认为html,因为查询结果可能是数组,那么也可以返回xml及json It's my fault,sorry.参数加的位置已经修改
顶一下

(0)
0%
踩一下

(0)
0%
- 相关评论
- 我要评论
-