0
我使用的Neo4j REST API和做一個jQuery的AJAX調用這是我第一次與RESTNeo4j的訪問控制頭
我試圖做這樣的呼籲:使用
$.ajax({
url: "http://localhost:7474/db/data/cypher",
accepts: "application/json; charset=UTF-8",
contentType:"application/json",
dataType:"json",
data:{
"query" : "start n = node(*) return n",
"params" : {}
},
type:"POSt",
success:function(data,xhr,status)
{
console.log(data);
},
error:function(xhr,err,msg){
console.log(xhr);
console.log(err);
console.log(msg);
}
});
這一點,我得到以下錯誤:
XMLHttpRequest cannot load http://localhost:7474/db/data/cypher.
No 'Access-Control-Allow-Origin' header is present on the requested resource.
Origin 'http://localhost' is therefore not allowed access.
在此之後我用Google搜索,並得到了答案HERE,但我不理解的錯誤,所以我谷歌d還,但它不是任何幫助,所以如果有人能告訴我這是什麼錯誤清晰的語言意味着,如果我不會刪除contenttype
條款它在未來
由於產生問題,金潤
爲什麼在這裏刪除的contentType? –
請參閱編輯... – MYK