Behavior
If I go to: http://localhost/login
... everything works as acceptected
If I go to: http://localhost/login/
.. I get redirected to: http://localhost/var/www/public/login
Expected behavior is for the trailing slash to be removed:
http://localhost/login/
=>> http://localhost/login
.htaccess:
RewriteEngine On
RewriteRule (.+)/$ /$1 [L,R=301]
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
Question
- Why doesn't it work as expected?
- How do I make it work as expected?