Can anyone see why this doesn't redirect?
RewriteEngine On
RewriteRule ^case-studies(/)?$ index.php/portfolio/ [NC,L]
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
Fyi, although it shouldn't matter, I'm using Zend framework, just need to mask the '/portfolio' to '/case-studies' (picky client!)
Thanks
如果要将/portfolio
更改为/case-studies
,则需要颠倒顺序:
RewriteRule ^portfolio(/)?$ index.php/case-studies/ [NC,L]
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.