MooTools 请求 url 返回 404 错误页面
我遇到了麻烦,因为我的 MooTools AJAX 请求找不到我的 PHP 脚本 URL 请求。首先我有一个index.php,它加载到ControllerList.php(列出文件并删除每个文件),然后在该脚本中,我有这个MooTools脚本用于调用controllerDelete。
存在问题,因为它说:
404: The requested URL /Files/ControladorDelete.php was not found on this server.
这是我的项目的结构:
http: //imageshack.us/photo/my-images/717/imagen1nvj.png/
这是我的 MooTools 脚本:
window.addEvent('domready', function() {
$$('a.div').addEvent('click', function(e) {
e.stop();
var id_file = this.get('id');
var new = id_file.split('#');
var DeleteFile = new Request({
method: 'POST',
url: 'ControllerDelete.php?id_file='+new[1]+'&name='+new[0], ERROR
onRequest: function() {},
onSuccess: function() {
},
onFailure: function(){alert('Error!');}
}).send();
});
});
该请求不断给我错误。感谢您的帮助,
我已经更改为 URL:Controler/ControllerDelete.php 但它是相同的,我不知道如何修复它。
I am having trouble because my MooTools AJAX request doesn't find my PHP script URL request. First I have an index.php which loads in ControllerList.php (List files and delete each one), then in that script, I have this MooTools script for calling controllerDelete.
There is the problem because It says:
404: The requested URL /Files/ControladorDelete.php was not found on this server.
This is the structure of my project:
http://imageshack.us/photo/my-images/717/imagen1nvj.png/
This is my MooTools script:
window.addEvent('domready', function() {
$('a.div').addEvent('click', function(e) {
e.stop();
var id_file = this.get('id');
var new = id_file.split('#');
var DeleteFile = new Request({
method: 'POST',
url: 'ControllerDelete.php?id_file='+new[1]+'&name='+new[0], ERROR
onRequest: function() {},
onSuccess: function() {
},
onFailure: function(){alert('Error!');}
}).send();
});
});
The request keeps giving me error. Thanks for your help
I already changed to URL: Controler/ControllerDelete.php but Its the same and I don't know how to fix it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
一看你的文件夹树,我就知道你需要像这样形成你的 URL:
要修复你的错误。
One look at your folder tree tells me that you need to form your URL like this:
To fix your error.