I have a site that is set-up without stripping out the file extension of .php, so if someone wants to go to a page called rsvp.php, they can't just type into the browser www.somesite.com/rsvp
The site is pretty large and I think if I did set up an .htaccess file to strip out the .php, I'd have to change out all the forms which direct to their parent files with the .php appended in the form action field.
So the work around was creating a folder called promotion and then inside placing an index.php file to redirect to the rsvp.php file. That works great, unfortunately the customer put out fliers that shows the link in all capital letters. So some people type in www.somesite.com/rsvp and others type in www.somesite.com/RSVP. When they do it in uppercase, it doesn't go to the folder and says "page not found". And of course I can't create a separate folder with uppercase because then it'll replace the lowercase one.
Anyone know what I can do to resolve this?
Will a 301 redirect from the RSVP to rsvp not do the trick?
Just place the below code in your .htaccess file
Redirect 301 /RSVP http://www.somesite.com/rsvp
This works when someone types in www.somesite.com/RSVP, but not with www.somesite.com/rsvp
Originally Posted by seanmarkham
What if you did a redirect from rsvp to rsvp.php before, there wouldn,t be the need for the folder and index file you are currently redirecting to?
Originally Posted by cgdtalent
So redirect any attempt to rsvp to rsvp.php and redirect any attempt to RSVP to rsvp.php also.
Redirect 301 /rsvp http://www.somesite.com/rsvp.php
Redirect 301 /RSVP http://www.somesite.com/rsvp.php