[GH-ISSUE #2] nginx 405 #2

Closed
opened 2026-02-26 17:45:56 +03:00 by kerem · 4 comments
Owner

Originally created by @ldxw on GitHub (Dec 29, 2019).
Original GitHub issue: https://github.com/D3CODING/KMS-Server-WebUI/issues/2

伪静态
405 Not Allowed

Originally created by @ldxw on GitHub (Dec 29, 2019). Original GitHub issue: https://github.com/D3CODING/KMS-Server-WebUI/issues/2 伪静态 405 Not Allowed
kerem closed this issue 2026-02-26 17:45:56 +03:00
Author
Owner

@D3CODING commented on GitHub (Jan 5, 2020):

nginx不允许从html文件发出POST请求,将文件index.html改名为index.php即可。

<!-- gh-comment-id:570896629 --> @D3CODING commented on GitHub (Jan 5, 2020): nginx不允许从html文件发出POST请求,将文件`index.html`改名为`index.php`即可。
Author
Owner

@ldxw commented on GitHub (Jan 6, 2020):

nginx不允许从html文件发出POST请求,将文件index.html改名为index.php即可。

伪静态后下载的文件没后缀咋回事啊。。伪静态问题?nginx的

<!-- gh-comment-id:571162379 --> @ldxw commented on GitHub (Jan 6, 2020): > nginx不允许从html文件发出POST请求,将文件`index.html`改名为`index.php`即可。 伪静态后下载的文件没后缀咋回事啊。。伪静态问题?nginx的
Author
Owner

@D3CODING commented on GitHub (Jan 7, 2020):

文件名是通过设置请求响应头实现的,如果浏览器调用第三方下载器,可能会因为无法接收前端传递的POST参数导致下载脚本失败,可以尝试禁用第三方下载工具或将前端和后端改为GET请求。

<!-- gh-comment-id:571512296 --> @D3CODING commented on GitHub (Jan 7, 2020): 文件名是通过设置请求响应头实现的,如果浏览器调用第三方下载器,可能会因为无法接收前端传递的POST参数导致下载脚本失败,可以尝试禁用第三方下载工具或将前端和后端改为GET请求。
Author
Owner

@D3CODING commented on GitHub (Jan 7, 2020):

如果伪静态存在问题,可以尝试去掉伪静态,将前端index.html中的
<form action="./kms" method="post" role="form">
改为
<form action="./kms.php" method="post" role="form">
因为设置伪静态仅仅为了隐藏PHP后缀

<!-- gh-comment-id:571513210 --> @D3CODING commented on GitHub (Jan 7, 2020): 如果伪静态存在问题,可以尝试去掉伪静态,将前端index.html中的 `<form action="./kms" method="post" role="form">` 改为 `<form action="./kms.php" method="post" role="form">` 因为设置伪静态仅仅为了隐藏PHP后缀
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/KMS-Server-WebUI#2
No description provided.