Javascript Ajax正在从其他源返回数据
我对jquery中的$.ajax没有什么问题。我正在调用file response.php,但从index.php得到响应 文件结构:Javascript Ajax正在从其他源返回数据,javascript,php,jquery,html,ajax,Javascript,Php,Jquery,Html,Ajax,我对jquery中的$.ajax没有什么问题。我正在调用file response.php,但从index.php得到响应 文件结构: libs/response.php js/main.js ... index.php Index.php <!DOCTYPE html> <html> <head> ... <button id="bttClick">click</button> ... </html> Res
libs/response.php
js/main.js
...
index.php
Index.php
<!DOCTYPE html>
<html>
<head>
...
<button id="bttClick">click</button>
...
</html>
Response.php
<?
echo "ECHO";
?>
有人能帮忙吗?谢谢
答复:
.htaccess在libs之前添加斜杠/表示“url”:“/libs/response.php”index.php、main.js和response.php在哪里?完整路径please@user2899587ajax数据上的arr是什么?如果可能的话,请尝试在response.php中使用其他页面ajax call.htacces boys,谢谢
<?
echo "ECHO";
?>