C# 更新以从asp.net C运行php文件
在我的项目中,我想调用php文件。但它显示了一个错误405方法不允许。 请帮帮我C# 更新以从asp.net C运行php文件,c#,javascript,jquery,asp.net,C#,Javascript,Jquery,Asp.net,在我的项目中,我想调用php文件。但它显示了一个错误405方法不允许。 请帮帮我 $.ajax({ type: "POST", contentType: "application/json; charset=utf-8", url: "/index.php", data: "{}", dataType: "json", success: function (data) { alert("success"); },
$.ajax({
type: "POST",
contentType: "application/json; charset=utf-8",
url: "/index.php",
data: "{}",
dataType: "json",
success: function (data) {
alert("success");
},
error: function (result) {
alert("Error");
}
});
尝试“获取”方法而不是“发布”。Thnak很多……。如果有帮助,请标记为“已回答”。