I am working on my own personal site to make my urls more SEO compliant:
I have links that are like:
http://domain.tld/index.php?nav=social
That can be reduced to:
And after I added:
Apache Configuration
#remove .php
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteRule ^([^\.]+)$ $1.php [NC,L]
#for pretty url
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^([^\.]+)$ index.php?nav=$1 [NC,L]
To my .htaccess file, I can now access the file at:
Now for my real question:
I have links like:
http://domain.tld/?nav=footer&id=staff
and
http://domain.tld/?nav=games&id=gametype&page=pagename
How can I reduce them to:
"http://domain.tld/staff" and "http://domain.tld/games/gametype/pagename" respectively
Thank you for your help
I would really love an answer so if Alexander Ebert or Tim Düsterhus feel like answering I would be super happy.