ajax跨域

$.ajax({ 
    type: "get", 
    url: "http://"+host_url+":8800/index.php?action=login&ts=login&username="+uname+"&password="+pass+"&chekcode="+va+"&callback=jsonpCallback", 
     dataType: "jsonp", 
    success: function (data) {
             //alert(data.code);
    if(data.code == '101'){
     
     window.location.replace("http://"+host_url+":8800/index.php") ;
     return true;
    }
    } 
   });

 

注意:ajax跨域用get提交

posted @ 2014-04-03 22:03  Echo正在输入  阅读(158)  评论(0编辑  收藏  举报