欢迎光临
我们一直在努力

为什么java安装错误,载入java vm出现错误2

但在有些应用中,需要使静态文件能够响应POST请求。对于Nginx,可以修改nginc.conf配置文件,改变“405错误”为“200 ok”,并配置location来解决,方法如下:

. 代码如下:

server ? ?{ ? ? ? ?listen ?80; ? ? ? ?server_name www.jb51.net; ? ? ? ?index index.html index.htm index.php; ? ? ? ?root ?/opt/htdocs; ? ? ? ?if (-d $request_filename) ? ? ? ?{ ? ? ? ? ? ?rewrite ^/(.*)([^/])$ http://$host/$1$2/ permanent; ? ? ? ?} ? ? ? ?error_page ?405 =200 @405; ? ? ? ?location @405 ? ? ? ?{ ? ? ? ? ? ?root ?/opt/htdocs; ? ? ? ?} ? ? ? ?location ~ .*\.php?$ ? ? ? ?{ ? ? ? ? ? ?include conf/fcgi.conf; ? ? ? ? ? ? ? ?fastcgi_pass ?127.0.0美国高防vps.1:10080; ? ? ? ? ? ?fastcgi_index index.php; ? ? ? ?} ? ?}

22658962

赞(0)
【声明】:本博客不参与任何交易,也非中介,仅记录个人感兴趣的主机测评结果和优惠活动,内容均不作直接、间接、法定、约定的保证。访问本博客请务必遵守有关互联网的相关法律、规定与规则。一旦您访问本博客,即表示您已经知晓并接受了此声明通告。