I swear am not able to get this, i read 10 tutorials but unable to make it work…I wanted pretty urls so my directory structure goes like this
localhost/my_website/home.php?page=dashboard
I have an .htaccess file in my_website folder with these rules
#Redirect To Default Login Page
DirectoryIndex login.php
#Block Directory Listing
IndexIgnore *
# Turn on URL rewriting
RewriteEngine On
RewriteRule ^page/([^/\.]+)/?$ home.php?page=$1 [L]
But when I type this http://localhost/my_website/home/dashboard I actually do not get anything
What I get is
The requested URL /my_website/home/dashboard was not found on this server.
You may try this:
It will map silently:
http://localhost/my_website/anything1/anything2To:
http://localhost/my_website/anything1.php?page=anything2I assumed
homeanddashboardin the question are variables (Can be anything).