Ecommerce software home
Shopping Cart Software Forum for Ecommerce Templates
 
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

Find us on Facebook Follow us on Twitter View our YouTube channel
Search our site
Forum Search
Google Site Search
 All Forums
 Technical
 PHP (Unix / Linux / Apache) versions
 SEO Friendly URL question
Author « Topic »  

Marshall
Ecommerce Template Guru

USA
1945 Posts

Posted - 09/29/2025 :  22:08:38  
Is it possible to do this
RewriteRule ^products/([^/]*)/?$ /products.php?cat=$1 [QSA,nc,L,B]
this way
RewriteRule (.*) /products.php?cat=$1 [QSA,nc,L,B]

When using RewriteRule ^products/([^/]*)/?$ /products.php?cat=$1 [QSA,nc,L,B], it is returning No Products Currently available with the static page categories as it is putting them /category/static-page.php rather than putting the static page at the root level.

Marshall
CENLYT Productions - ms designs
Affordable Web Design
Custom Ecommerce Designs
Responsive Websites
Cenlyt.com

Vince
Administrator

43125 Posts

Posted - 09/30/2025 :  04:19:22  
Hi Marshall
If you want to exclude static pages would the idea be to add a rewrite condition that the page not be a file or directory like this?

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

Vince

Click Here for Shopping Cart Software
Click Here to sign up for our newsletter
Click Here for the latest updater

Marshall
Ecommerce Template Guru

USA
1945 Posts

Posted - 09/30/2025 :  06:15:06  
This is what I currently have in the .htaccess after what I described happened

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) proddetail.php?prod=$1 [QSA,nc,L,B]

And this is what is in the vsadmin.php

$seodetailurls=TRUE;
$detlinkspacechar="-";
$seourlsthrow301=TRUE;

However, this is what I had that caused the problem

RewriteRule ^category/([^/]*)/?$ /categories.php?cat=$1 [QSA,nc,L,B]
RewriteRule ^products/([^/]*)/?$ /products.php?cat=$1 [QSA,nc,L,B]
RewriteRule ^manufacturer/?$ /categories.php?man=all [QSA,nc,L,B]
RewriteRule ^manufacturer/([^/]*)/?$ /products.php?man=$1 [QSA,nc,L,B]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule (.*) proddetail.php?prod=$1 [QSA,nc,L,B]

And this in the vsadmin.php

$seodetailurls=TRUE;
$seocategoryurls=TRUE;
$detlinkspacechar="-";
$seocaturlpattern="/category/%s";
$seoprodurlpattern="/products/%s";
$seourlsthrow301=TRUE;




Marshall
CENLYT Productions - ms designs
Affordable Web Design
Custom Ecommerce Designs
Responsive Websites
Cenlyt.com
  « Topic »  
Jump To:
Shopping Cart Software Forum for Ecommerce Templates © 2002-2022 ecommercetemplates.com
This page was generated in 0.03 seconds. Snitz Forums 2000