htaccess 301重定向无法正常工作

时间:2011-04-13 19:07:28

标签: drupal .htaccess drupal-6

我正在尝试将旧网页重定向到新网页,但这不起作用。我在.htaccess文件的最开头添加了这些“重定向”。当我在底部添加时,它给出了服务器配置错误。如何使它工作? 同样适用于我的基于Joomla的网站。 当我在Firefox中输入“http://www.indiacustomercare.com/toll-free-customer-care-numbers-in-india.html”时,它会给出错误:

  

页面未正确重定向   Firefox已检测到该服务器   正在重定向此请求   以永远不会的方式解决   完整。

*   This problem can sometimes be caused by disabling or refusing to
     

接受             饼干。

以下是我在.htaccess

开头添加的行
  redirect 301 /toll-free-customer-care-numbers-in-india.html http://www.indiacustomercare.com/toll-free-customer-care-numbers-india
    redirect 301 /vodafone-customer-care.html http://www.indiacustomercare.com/vodafone-customer-care-helpline-numbers
    redirect 301  /airtel-customer-care.html http://www.indiacustomercare.com/airtel-customer-care-contact-helpline-call-center-numbers
    redirect 301 /xmap-1.html   http://www.indiacustomercare.com/sitemap
    redirect 301 /index.html  http://www.indiacustomercare.com/reciprocal-link-exchange-add-your-url

1 个答案:

答案 0 :(得分:0)

这很有用。我在.htaccess

的顶部添加了这个
RewriteBase / 
RewriteRule ^index.html$ indiacustomercare.com/reciprocal-link-exchange-add-your-url [R=301,L]