Hi All, i need help with what i thought would be a simple 301 redirect. I need to redirect this page: http://www.example.co.uk/shop/shop.php?c1=Accessories to: http://www.example.co.uk/accessories.htm Both urls are on the same domain. can anyone help?
Add the following strings to the .htaccess file: RewriteEngine on RewriteRule ^http\:\/\/www\.example\.co\.uk\/shop\/shop\.php\?c1\=Accessories$ http\:\/\/www\.example\.co\.uk\/accessories\.htm [R=301,L] Code (markup): Another way is to modify the shop.php script if ($c1 = 'Accessories') { header('Location: http://www.example.co.uk/accessories.htm'); exit; } PHP: