Forum Moderators: phranque
about.php
contact.php
section/page1.php
etc etc but I would like it so you simply had to type in the following
/about
/contact
/section/page1
etc etc
I really haven't got a clue when it comes to this kind of programming and looking around the web, and this forum it all seems like jargon to my design based mind!
I'm sure this is a very simple request but can anyone help? Any advice would be very much appreciated.
rewrite to connect the URL request to the internal server filename. Use a RewriteRule for this. It uses very similar syntax to a redirect; but for a rewrite the target should not contain a domain name.
Use [L] at the end of the rule. Post your best effort code here with details of what problems you are having.
You'll also need to update the URLs in the links on your pages to use the new format as it is links that 'define' URLs.
You will also need to set up a conditional 301 redirect such that if anyone directly requests a URL that ends with .php that they are redirected to make a new request for the new URL. Failure to implement the 301 redirect will mean that both versions of the URL will return Duplicate Content - and that is bad. The redirect should also force www for those URLs at the same time.