4
我目前正在将我的网站从Apache迁移到nginx
,但我的.htaccess
文件无法运行。我的网站位于/usr/share/nginx/html/mywebsite
文件夹内。我如何在我的nginx
服务器中使用.htaccess
?如何在nginx中使用.htaccess文件
这是我.htaccess
文件:
RewriteEngine on
RewriteRule video/watch/([[email protected]$*-]+)/?$ "videos-single.php?id=$1" [NC]
其中nginx.conf文件位于 –
我认为'/ etc/nginx/nginx.conf' - 请参阅'nginx'软件包的文件列表。 – uzsolt
我同意,.htaccess是邪恶的。但是,在处理遗留代码时,有充分的理由支持它。这是一个我刚刚开始模拟.htaccess for nginx的项目:https://github.com/e404/htaccess-for-nginx - 欢迎任何帮助! – Gerald