最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

url rewriting - Rewrite htacess rule doesn't work

programmeradmin0浏览0评论

Inside the page directory I have multiple pages such as admin-add-account, registration, and I'm trying to rename them from www.example/page/admin-add-account.php to www.example/admin-add-account. I've tried this but it's not working, what am I doing wrong? Thanks!

RewriteEngine On
RewriteBase /page/

RewriteRule ^register/?$ registration.php [L,NC]
RewriteRule ^forget-password/?$ forget-password.php [L,NC]
# ignore files/directories from further rules
RewriteCond %{REQUEST_FILENAME} -d [OR]
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^ - [L]
发布评论

评论列表(0)

  1. 暂无评论