So i have been try to figure out how to make my link search engine friendly and i have learned so far that the .htaccess file has to be in the root directory of the website Folder. The following is the contents of the folder which i think it has an error because it keeps getting hidden from the wamp server
RewriteEngine On
Options FollowSymLinks
RewriteRule ^(([a-zA-Z0-9])*\/([a-zA-Z0-9])*)*$ $1.php?article=$2
Now i am trying to do the following.
Turn this link :http://localhost:63342/EuroSkills/View/Beer.php?article=6
Into this link http://localhost:63342/EuroSkills/View/Beer6
What i am changing is that beer.php file into just beer
Place code in your /EuroSkills/.htaccess
file:
RewriteEngine On
RewriteBase /EuroSkills/View/
RewriteRule ^([a-z]+)([0-9]+)/?$ $1.php?article=$2 [L,NC,QSA]
They way I handled URLs in an old PHP application I had, is to map ALL urls to index.php. Then use PHP code to parse out $_REQUEST the path that was requested, and make the decisions there.