我在我的網站上使用Valums Ajax Uploader。一切工作正常我本地計算機上,但是當我嘗試我的網站主服務器上的相同上傳然後Firbug顯示了這個錯誤:valums Ajax文件上傳+ 406不可接受Error in Firbug
POST http://www.myexampledomain.com/upload.php?qqfile=201004151821387.1.flv 406不可接受8.37s
fileuploader.js(線1204)
響應體
<title>406 Not Acceptable</title>
<p>An appropriate representation of the requested resource /upload.php could not be found on this server.</p>
<p>Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.</p>
所有請求&響應頭是here和fileuploader.js
的文件代碼到附近號線1204:
params = params || {};
params['qqfile'] = name;
var queryString = qq.obj2url(params, this._options.action);
xhr.open("POST", queryString, true);
xhr.setRequestHeader("X-Requested-With", "XMLHttpRequest");
xhr.setRequestHeader("X-File-Name", encodeURIComponent(name));
xhr.setRequestHeader("Content-Type", "application/octet-stream");
xhr.send(file); //line 1204
我已經搜索在谷歌和這個網站,但沒有什麼可被發現,所以請告訴我,我該如何解決這個問題呢?
我關於這個問題的其他問題 - 406 error on firebug only
upload.php也在正確的文件夾,我通過直接訪問它來檢查它 – Peeyush
是否一個簡單的'.txt'文件上傳沒有錯誤?還是所有的上傳都失敗了? – andyb
no .txt也會導致相同的406錯誤 – Peeyush