Jump to content

301 redirect htaccess


q-skins.dk

Recommended Posts

i have been trying to reirect some old pages to new existing pages but not sure i am doing this the right way so neew help verifying my method:

 

i have done this:

 

 

# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution

# WARNING: PLEASE DO NOT MODIFY THIS FILE MANUALLY. IF NECESSARY, ADD YOUR SPECIFIC CONFIGURATION WITH THE HTACCESS GENERATOR IN BACK OFFICE

# http://www.prestashop.com - http://www.prestashop.com/forums

 

 

<IfModule mod_rewrite.c>

# URL rewriting module activation

RewriteEngine on

Redirect 301 /q-skins.dk/shop/skins/ http://q-skins.dk/5-skins-og-covers'>http://q-skins.dk/5-skins-og-covers

Redirect 301 /q-skins.dk/shop/baggrunde/ http://q-skins.dk/9-baggrunde'>http://q-skins.dk/9-baggrunde

Redirect 301 /q-skins.dk/produkt/1027/ http://q-skins.dk/19-ipad-2-the-new-ipad-3'>http://q-skins.dk/19-ipad-2-the-new-ipad-3

Redirect 301 /q-skins.dk/?page_id=621/ http://q-skins.dk

Redirect 301 /q-skins.dk/?author=1/ http://q-skins.dk

Redirect 301 /q-skins.dk/faq/handelsvilkar-2/ http://q-skins.dk/content/12-mest-stillede-sporgsmal-q-skinsdk

 

 

# URL rewriting rules

RewriteRule ^([a-z0-9]+)\-([a-z0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2$3.jpg [L]

RewriteRule ^([0-9]+)\-([0-9]+)/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1-$2.jpg [L]

RewriteRule ^([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$1$2.jpg [L]

RewriteRule ^([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$1$2$3.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$1$2$3$4.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$1$2$3$4$5.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$1$2$3$4$5$6.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$1$2$3$4$5$6$7.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$7/$1$2$3$4$5$6$7$8.jpg [L]

RewriteRule ^([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])([0-9])(\-[_a-zA-Z0-9-]*)?/[_a-zA-Z0-9-]*\.jpg$ /img/p/$1/$2/$3/$4/$5/$6/$7/$8/$1$2$3$4$5$6$7$8$9.jpg [L]

RewriteRule ^c/([0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/c/$1$2.jpg [L]

RewriteRule ^c/([a-zA-Z-]+)/[a-zA-Z0-9-]+\.jpg$ /img/c/$1.jpg [L]

RewriteRule ^([0-9]+)(\-[_a-zA-Z0-9-]*)/[_a-zA-Z0-9-]*\.jpg$ /img/c/$1$2.jpg [L]

RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L]

RewriteRule ^[a-zA-Z0-9-]*/([0-9]+)\-[a-zA-Z0-9-]*\.html /product.php?id_product=$1 [QSA,L]

RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]*(/[a-zA-Z0-9-]*)+ /category.php?id_category=$1&noredirect=1 [QSA,L]

RewriteRule ^([0-9]+)\-[a-zA-Z0-9-]* /category.php?id_category=$1 [QSA,L]

RewriteRule ^([0-9]+)__([a-zA-Z0-9-]*) /supplier.php?id_supplier=$1 [QSA,L]

RewriteRule ^([0-9]+)_([a-zA-Z0-9-]*) /manufacturer.php?id_manufacturer=$1 [QSA,L]

RewriteRule ^content/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms=$1 [QSA,L]

RewriteRule ^content/category/([0-9]+)\-([a-zA-Z0-9-]*) /cms.php?id_cms_category=$1 [QSA,L]

RewriteRule ^page-not-found$ /404.php [QSA,L]

RewriteRule ^address$ /address.php [QSA,L]

RewriteRule ^addresses$ /addresses.php [QSA,L]

RewriteRule ^authentication$ /authentication.php [QSA,L]

RewriteRule ^best-sales$ /best-sales.php [QSA,L]

RewriteRule ^cart$ /cart.php [QSA,L]

RewriteRule ^kontakt-os$ /contact-form.php [QSA,L]

RewriteRule ^discount$ /discount.php [QSA,L]

RewriteRule ^guest-tracking$ /guest-tracking.php [QSA,L]

RewriteRule ^order-history$ /history.php [QSA,L]

RewriteRule ^identity$ /identity.php [QSA,L]

RewriteRule ^manufacturers$ /manufacturer.php [QSA,L]

RewriteRule ^my-account$ /my-account.php [QSA,L]

RewriteRule ^nyheder$ /new-products.php [QSA,L]

RewriteRule ^order$ /order.php [QSA,L]

RewriteRule ^order-follow$ /order-follow.php [QSA,L]

RewriteRule ^quick-order$ /order-opc.php [QSA,L]

RewriteRule ^order-slip$ /order-slip.php [QSA,L]

RewriteRule ^password-recovery$ /password.php [QSA,L]

RewriteRule ^tilbud$ /prices-drop.php [QSA,L]

RewriteRule ^search$ /search.php [QSA,L]

RewriteRule ^sitemap$ /sitemap.php [QSA,L]

RewriteRule ^stores$ /stores.php [QSA,L]

RewriteRule ^supplier$ /supplier.php [QSA,L]

</IfModule>

 

# Catch 404 errors

ErrorDocument 404 /404.php

 

hope somebody can and will help me.

Thanks.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...