Jump to content

[help]friendly url error using hostgator


Recommended Posts

When i push the generator button for .htacces i just got these.

# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
# http://www.prestashop.com - http://www.prestashop.com/forums

# Catch 404 errors
ErrorDocument 404 /404.php



is it okay??

Btw, before i did that generators. Im using redirect from cpanel to redirect non www to www.

Please help.

Thank You

Link to comment
Share on other sites

  • 2 weeks later...

Here is my .htaccess file content:

# URL rewriting module activation
RewriteEngine on
RewriteCond %{REQUEST_METHOD} !^(TRACE|TRACK|GET|POST|HEAD)$
RewriteRule .* - [F]
RewriteBase /
Options +FollowSymLinks

DirectoryIndex index.php

# URL rewriting rules
RewriteCond %{HTTP_HOST} ^YOURDOMAIN.com [NC] 
RewriteRule ^(.*)$ http://www.YOURDOMAIN.com/$1 [L,R=301]
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

# CACHE ONE MONTH 

  Header set Cache-Control "max-age=2419200"


# CACHE ONE WEEK

  Header set Cache-Control "max-age=604800"


# NEVER CACHE

  Header set Expires "Thu, 31 Dec 2009 23:59:59 GMT"
  Header set Cache-Control "no-store, no-cache, must-revalidate"
  Header set Pragma "no-cache"

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...