Click to See Complete Forum and Search --> : What is [R=301,NC]?
fr600
02-12-2007, 02:47 PM
A line in one of my htaccess is:
RewriteRule ^images.html /index.html [R=301,NC]
It redirects images.html to index.html.
My questions are:
What is [R=301,NC]? What does it do? How is it related to search engines?
Please tell me. Reply briefly if you want. Thanks.
scrupul0us
02-12-2007, 02:52 PM
R=301 mean redirect 301 errors (page moved permanently).. the NC im not sure
goldbug
02-12-2007, 02:54 PM
The NC stands for 'no case', aka the pattern is case-insensitive.
bradgrafelman
02-12-2007, 03:13 PM
How is it related to search engines? Well, I'm not sure exactly how they handle it, but generally it means the link that the engine indexed has been moved and that it should be updated with the new location.
For more information about mod_rewrite, see this (http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html) page.
fr600
02-12-2007, 03:19 PM
Thanks for the reply. I have 1 more question atm.
I've redirected all old pages to index.html like:
RewriteRule ^images.html /index.html [R=301,NC]
RewriteRule ^images2.html /index.html [R=301,NC]
RewriteRule ^images3.html /index.html [R=301,NC]
...etc
In this case, search engines possibly won't index all index.html seperately. Only 1 will be indexed and others will be removed from search result, isn't it?
bradgrafelman
02-12-2007, 03:22 PM
As I said, I'm not exactly sure how the different spiders will deal with this, but in essence a 301 is telling them "Hey, the link you just followed shouldn't be used anymore - get rid of it! It's not going to work anymore! Instead, you should use this one: ..."
PHP Builder
Copyright WebMediaBrands Inc. All Rights Reserved.