我正在使用这个人的剧本
一个。 Valums http://valums.com/ajax-upload/
在文件上传完成之前,一切都很好,我在firebug上遇到406错误(仅限)。当我右键单击firebug上的链接并在新窗口中打开时,该文件确实存在并执行我期望它执行的操作。
firebug上的页面说
Not Acceptable An appropriate representation of the requested resource upload.php could not be found on this server. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
但是当我在新标签上看到该页面时,它运行正常并返回正确的内容,A上的该脚本具有ajax请求btw
更新
Host www.example.com User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13 Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language en-gb,en;q=0.5 Accept-Encoding gzip,deflate Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7 Keep-Alive 115 Connection keep-alive Content-Type application/octet-stream Referer http://www.example.com Content-Length 192378 Cookie
答案 0 :(得分:0)
查看HTTP标头。您的JavaScript可能会添加一个Accept
标头,服务器认为它没有合适类型的数据来响应。
答案 1 :(得分:0)
这是一个服务器error.something称为“mod_security”需要被禁用,我不知道它是什么,但问你的托管服务提供商,如果你遇到问题,他们应该知道它:)