Magento Forum

   
htaccess redirect with multiple querystrings
 
denialdesign
Jr. Member
 
Total Posts:  5
Joined:  2012-02-12
 

I’m trying to redirect the urls of my old ASP shop to new Magento search engine friendly urls in my .htaccess file.
The old site had 2 levels of categories and so far I’ve got the top level caegories redirecting successfully like so

RewriteCond %{QUERY_STRING} ^catparentid=1
RewriteRule 
^shop\.asphttp://www.mydomain.com/acategory/? [R=301,L]

But I can’t seem to get the sub-categories to redirect to the right place. I’ve tried this:

RewriteCond %{QUERY_STRING} &?catparentid=2&catid;=14$
RewriteRule ^shop\.asphttp://www.mydomain.com/acategory/asubcategory/? [R=301,L]
but it just redirects to the parent category. Help please!!

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top