• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
8 simple 301 redirects not working

#1
[eluser]charlie spider[/eluser]
I think that too much work and not enough sleep is keeping me from figuring this out! I just need to set up 302 redirects for an 8 page site.

My htaccess file is set up as follows and works perfectly:

Code:
Options Indexes
Options +FollowSymLinks
Options -MultiViews
DirectoryIndex index.php

<IfModule mod_rewrite.c>

  RewriteEngine on
  RewriteBase /

  #RewriteCond %{HTTP_HOST} !^www\.coachhouse\.info$ [NC]
  #RewriteRule ^(.*)$ http://www.coachhouse.info/$1 [R=301,L]

   RewriteCond %{REQUEST_FILENAME} !-f
   RewriteCond %{REQUEST_FILENAME} !-d

   RewriteRule ^(.*)$ index.php?/$1 [NC,L,QSA]
  
</IfModule>

I initially tried to use regular 301 redirects like:

Code:
<IfModule !mod_alias.c>
redirect 301 /index.htm http://www.coachhouse.info
redirect 301 /features.htm http://www.coachhouse.info/features
redirect 301 /pender.htm http://www.coachhouse.info/pender-island
redirect 301 /location.htm http://www.coachhouse.info/location
redirect 301 /rates.htm http://www.coachhouse.info/rates-and-info
redirect 301 /testimonials.htm http://www.coachhouse.info/guest-comments
redirect 301 /contact.htm http://www.coachhouse.info/contact
redirect 301 /links.htm http://www.coachhouse.info/links
</IfModule>

but those would turn this:
http://www.coachhouse.info/rates.htm

into this:
http://www.coachhouse.info/rates-and-info?/rates.htm

Apparantly you can't mix mod_alias with the mod_rewrite rules for removing index.php from the url.


So then I tried to set up the 301 redirects using rewrite rules like this:

Code:
RewriteRule ^/rates.htm /rates-and-info [R=301]

or this:

Code:
RewriteRule ^/rates(.*) /rates-and-info [R=301]

or this:

Code:
RewriteRule ^/rates(.*) /rates-and-info [R=301,L]

or this:

Code:
RewriteRule ^/rates(.*) /rates-and-info$ [R=301,L]

and every variation/combination of the above I could think of including:

Code:
RewriteRule ^/rates(.*) /rates-and-info [R=301,L,PLEASE GOD PLEASE]



I have tried placing the rules at the end of the:
<IfModule mod_rewrite.c>

and I've tried placing them immediately after
RewriteBase /



but regardless of what I do, a request for http://www.coachhouse.info/rates.htm results in a 404 error.

And I have cleared the cache, tried other browsers, and restarted the browsers between attempts to no avail.

It just doesn't work.


What am I missing or doing wrong ?

Any and all help is greatly appreciated.

Thank you for your time.


Messages In This Thread
8 simple 301 redirects not working - by El Forum - 06-01-2010, 01:29 AM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 01:51 AM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 02:08 AM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 02:16 AM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 03:01 AM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 01:21 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 01:56 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 01:59 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 02:25 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 02:35 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 02:53 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 03:16 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 03:51 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 05:42 PM
8 simple 301 redirects not working - by El Forum - 06-01-2010, 10:53 PM
8 simple 301 redirects not working - by El Forum - 06-02-2010, 07:19 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.