小编pun*_*pta的帖子

ajax调用没有响应

当我直接在浏览器的地址栏中发布ajax url时,我正在使用ajax从远程服务器检索数据,我正在获取数据但是当我在javascript文件中对该URL进行ajax调用时,它显示错误.我在这里粘贴我的代码.

<!DOCTYPE html>
<html>
<head>

<script src="http://code.jquery.com/jquery-latest.js"></script>
<script>
$.ajax({
url:"http://www.appitechture.com/api/index.php?action=getContactDetails&id=96",
type:'get',
datatype:'json',
success:function OnSuccess(data , status){
  alert(data);
   } ,

error: function OnError(request , status , error){
        alert('error');
      }
 });
 </script>

 </head>
 <body>
  <div id="images"></div>
 </body>
  </html> 
Run Code Online (Sandbox Code Playgroud)

所以如果有人知道它的解决方案,请告诉我.

谢谢你的puneet

php ajax jquery

3
推荐指数
1
解决办法
73
查看次数

标签 统计

ajax ×1

jquery ×1

php ×1