I currently have a website with URLs with this pattern
https://website.com/?p=something
where p is the requested page (like /?p=login)
for SEO reasons i want the URL to look like this
https://website.com/login/
Of course I could do a redirect like this
Redirect 301 /login/ https://website.com/?p=login
But it would change the URL displayed in the users browser back to the URL with parameters in it.
My question is, how can I have an URL like this https://website.com/login/ but in PHP inside the index.php I could access the requestet page or "path" like before like $page = $_GET['p'];. In other words I want to redirect the URL https://website.com/login/ to https://website.com/?p=login but having the URL still displayed as https://website.com/login/.