您的位置 首页 技术文章 出现nginx 405 Not Allowed错误的解决方法 liveob 发布于 2024年9月14日 评论(0) 阅读(31) 1 nano nginx.conf 添加以下内容: 123456789101112 server { listen 80; server_name localhost; location / { root html; index index.html index.htm; } error_page 404 /404.html; error_page 403 /403.html; # To allow POST on static pages 允许静态页使用POST方法 error_page 405 =200 $uri; }