Creating SEO URL's without generating HTML pages

1. Create an .htaccess or alter your apache config file to add the the following mod_rewrite entries:

RewriteEngine on
Options +FollowSymLinks
RewriteBase /

RewriteRule catalog/([a-zA-Z0-9-.]*)/([a-zA-Z0-9-.]*)-([0-9]*).html$ /index.php?l=product_detail&p=$3
RewriteRule catalog/new-products-0-1.html$ /index.php?l=product_list&c=new
RewriteRule catalog/new-products-0-([0-9]*).html$ /index.php?pg=$1&l=product_list&c=new
RewriteRule catalog/([a-zA-Z0-9-.]*)-0-1.html$ /index.php?l=product_list&c=$1
RewriteRule catalog/([a-zA-Z0-9-.]*)-0-([0-9]*).html$ /index.php?pg=$2&l=product_list&c=$1
RewriteRule catalog/m-([a-zA-Z0-9-.]*)-([0-9]*)-1.html$ /index.php?l=product_list&m=$2
RewriteRule catalog/m-([a-zA-Z0-9-.]*)-([0-9]*)-([0-9]*).html$ /index.php?pg=$3&l=product_list&m=$2
RewriteRule catalog/([a-zA-Z0-9-.]*)-([0-9]*)-1.html$ /index.php?l=product_list&c=$2
RewriteRule catalog/([a-zA-Z0-9-.]*)-([0-9]*)-([0-9]*).html$ /index.php?pg=$3&l=product_list&c=$2
RewriteRule catalog/([a-zA-Z0-9]*).html$ /index.php?l=page_view&p=$1
RewriteRule catalog/([a-zA-Z0-9.]*)-([a-zA-Z0-9.]*).html$ /index.php?l=page_view&p=$1_$2
RewriteRule catalog/([a-zA-Z0-9.]*)-([a-zA-Z0-9.]*)-([a-zA-Z0-9]*).html$ /index.php?l=page_view&p=$1_$2_$3

2. Open the index.php and change the lines containing:

// Set Base URL
if ($_GET[setbase] == 1) $index[base_url] = '<base href="'.((is_secure())?$settings[secureurl]:$settings[shopurl]).'" />';


// Set Base URL
$index[base_url] = '<base href="'.((is_secure())?$settings[secureurl]:$settings[shopurl]).'" />';

3. Lastly, on the "Generate HTML Pages" area of the general setting within the admin, change the "Manufacturer Page Format:" from




You are all set! Now just turn HTML pages on. No need to generate HTML pages though. Additionally, making any changes to the format of URL's will require some slight mods to the rewrites.

  • 111 Users Found This Useful
Was this answer helpful?

Related Articles

Altering template text and language variables.

In this example we will alter the text in the Welcome Message template. Method 1: 1. In your...

Changing your shop logo.

To add or change the default logo within SunShop: 1. First login to the admin area of your shop...

Changing the default cart theme or skin.

To change the default theme or skin within SunShop: 1. First login to the admin area of your...

Adding "Add To Cart" to your own HTML pages.

Assuming you have your own button image and know the path/url to it, you would add the following...

Adding additional pages within SunShop.

1. Login to your Sunshop administration area and go to "Settings" -> "Manage Templates". 2....