Daily Archives: October 1, 2007

Ajax.Request Returning 405 Http Response

Today I experienced the problem of 405 HTTP Response on a production server while that didn’t happen in the test instance. This happened when doing an Ajax request using prototype.js Ajax.Request. The request is to fetch some static html. After a bit of a struggle, I realized that the default method option of Ajax.Request is POST and if the server is not configured (I don’t know how) to treat POST as GET for static content, this issue can happen. So, adding method: “GET” to the options list solved the problem.


Filed under AJAX