0

I've currently got a website with links like this:

mywebsite.com/page.php?name=Sport

how can I use htaccess to rename these pages so they can be found here:

mywebsite.com/Sport

(so in other words, removing "page.php?name=" from each URL)

AND if I do this, will it be case sensitive? (eg will mywebsite.com/sport be OK?)

AND if I do this, will the page still be able to do a $_GET["name"] so I can do stuff with the name variable in PHP?

Been trying to work out the htaccess commands - and I'm stuck. Thanks in advance!

** EDIT I can see other answers but I can't get my version to work, that's the problem. This is what I've got:

Options +FollowSymLinks

RewriteEngine On

RewriteRule ^/([A-Za-z0-9-+]+)/?$ /page.php?name=$1 [NC,L,QSA]

Community
  • 1
  • 1

0 Answers0