$("#userBarSignup").click(function(){
$.get("C:/xampp/htdocs/webname/resources/templates/signup.php",
{/*params*/},
function(response){
$("#signup").html("TEST");
$("#signup").html(response);
},
"html");
但是从 Google Chrome 的 JavaScript 控制台中,我一直收到此错误:
XMLHttpRequest 无法加载 file:///C:/xampp/htdocs/webname/resources/templates/signup.php。跨域请求仅支持 HTTP。
问题在于 signup.php 文件托管在我的本地 Web 服务器上,这就是整个网站的运行位置,因此不涉及跨域。
我该如何解决这个问题?
allow_url_include = On
。 - siannone