Ajax POST error 405
Denis F. Latypoff
denis at gostats.ru
Tue Nov 20 11:34:12 MSK 2007
Hello Ferenc-lorant,
Tuesday, November 20, 2007, 2:16:25 PM, you wrote:
> Ijust installed ngnix on my server. All rail applications works perfect,
> but i have some static sites where i use AJAX for content replacement
> and i get 405 Not allowed error.
> Server config:
> server {
> listen 80;
> server_name www.clean-tech.ro clean-tech.ro ;
> access_log /srv/www/vhosts/clean-tech/www/log/nginx.log main;
> location / {
> root /srv/www/vhosts/clean-tech/www;
> index index.html index.htm;
> }
> #error_page 404 /404.html;
> error_page 500 502 503 504 /50x.html;
> location = /50x.html {
> root /srv/www/htdocs/;
> }
> }
> I tried
> error_page 405 = @405;
> location = @405 {
> root /srv/www/vhosts/clean-tech/www;
> }
> but after this workaround i get error 500
why aren't you using GET requests instead of POST?
> Headers:
> Host clean-tech.ro
> User-Agent Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.9)
> Gecko/20071101 SUSE/2.0.0.9-2.1 Firefox/2.0.0.9
> Accept text/javascript, text/html, application/xml, text/xml, */*
> Accept-Language en-us,en;q=0.5
> Accept-Encoding gzip,deflate
> Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7
> Keep-Alive 300
> Connection close
> X-Requested-With XMLHttpRequest
> X-Prototype-Version 1.5.0_rc1
> Content-Type application/x-www-form-urlencoded
> Referer http://clean-tech.ro/
> Content-Length 0
> Cookie
> __utmz=240299857.1195540804.10.5.utmccn=(referral)|utmcsr=blog.hkcc.ro|utmcct=/2007/11/16/test|utmcmd=referral;
> __utma=240299857.1171685038.1191992038.1195504186.1195540804.10;
> __utmb=240299857; __utmc=240299857
> Pragma no-cache
> Cache-Control no-cache
--
Best regards,
Denis mailto:denis at gostats.ru
More information about the nginx
mailing list