I'm studying routing, trying to (re) create a routing solution of mine.
I have always used the following .htaccess
to redirect my requests:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.+)$ index.php?url=$1 [L]
That was easy, just get the $_GET['url']
no index.php
and treat as I'd like.
But I've come across the following .htacesss
:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php [L]
My question is how to take what was passed, since it does not throw the request in $_GET['url']
.