Jump to content

Url rewriting and SEO


Recommended Posts

Hi,

My shop is running with V1.1, url rewriting is on, my .htaccess file seems ok, but despite this, some of my pages are indexed with the url " ... product.php?id... " . How can this happen, and how can I get the robots to read and index only the rewrited urls ?

Thanks

Link to comment
Share on other sites

Yes, I though about using this kind of redirection, but I don't know about the correct script to use

This is my .ht access :

# URL rewriting module activation
RewriteEngine on
RewriteCond %{HTTP_HOST} ^ann-secret.com$ [NC]
RewriteRule ^(.*)$ http://www.ann-secrets.com/$1'>http://www.ann-secrets.com/$1 [R=301,L]




# URL rewriting rules
RewriteRule ^([a-zA-Z0-9-]*)/([0-9]+)\-([a-zA-Z0-9-]*)\.html(.*)$ product.php?id_product=$2$4 [L,E]
RewriteRule ^([0-9]+)\-([a-zA-Z0-9-]*)\.html(.*)$ product.php?id_product=$1$3 [L,E]
RewriteRule ^([0-9]+)\-([a-zA-Z0-9-]*)(.*)$ category.php?id_category=$1 [QSA,L,E]
RewriteRule ^content/([0-9]+)\-([a-zA-Z0-9-]*)(.*)$ cms.php?id_cms=$1 [QSA,L,E]
RewriteRule ^([0-9]+)__([a-zA-Z0-9-]*)(.*)$ supplier.php?id_supplier=$1$3 [QSA,L,E]
RewriteRule ^([0-9]+)_([a-zA-Z0-9-]*)(.*)$ manufacturer.php?id_manufacturer=$1$3 [QSA,L,E]

# Catch 404 errors
ErrorDocument 404 /404.php

SetEnv PHP_VER 5
SetEnv REGISTER_GLOBALS 0

ErrorDocument 401 http://www.ann-secrets.com/
ErrorDocument 403 http://www.ann-secrets.com/
ErrorDocument 404 http://www.ann-secrets.com/
ErrorDocument 500 http://www.ann-secrets.com/

Link to comment
Share on other sites

  • 2 months later...
×
×
  • Create New...