如何将没有查询字符串的URL重定向到带有查询字符串的URL?

时间:2015-12-29 16:35:38

标签: regex .htaccess mod-rewrite seo url-redirection

我已经四处寻找我的问题的答案但只是更加困惑。我希望有人可以帮助我...

我需要重定向此网址:

http://www.testsite.co.uk/ecommerce/cabinets/aluminium_cabinets

要:

http://www.testsite.co.uk/products/cabinets/?types[]=illuminated-aluminium-cabinets&types[]=non-illuminated-aluminium-cabinets

请帮助:)

1 个答案:

答案 0 :(得分:0)

尝试:

 RedirectMatch ^/ecommerce/cabinets/aluminium_cabinets/?$ http://www.testsite.co.uk/products/cabinets/?types[]=illuminated-aluminium-cabinets&types[]=non-illuminated-aluminium-cabinets