ajax post get请求
/*function ajax(type,url,fnSucess,fnFail,data){ //对于非必须参数的处理 //考虑参数过多的情况 xhr.open(type,url,true)}*///{type:"get",url:"demo.php",fnSuccess:foo,fnFail:bar,data:data}//data{username:"aaaa",password:1111}=>"username=aaaa&password=1111"function ajax(obj)
复制链接