Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
这在 Nginx 中是否可行:
当用户查询时www.example.com/a/b/c,nginx返回一个映射到的静态文件/home/www/example/a/b/c.html?
www.example.com/a/b/c
/home/www/example/a/b/c.html
如果是这样,我应该如何构建 nginx 配置的位置部分?
这是很有可能的,例如:
server { root /home/www/example; location / { try_files $uri.html $uri $uri/; } }
这将为每个请求检查是否: