I would just use a few FallbackResource directives instead. On Thu, Mar 22, 2018 at 8:27 PM, Rajib Karmakar <creativewebl...@gmail.com> wrote:
> Hello, > > Issues Facing for multiple htaccess rule for dynamic slug. > Mainly for an eCommerce website starting from which has > Department,category,subcategory,subsubcategory and product > > Sitepath are follows from department to subsubcategory > http://www.mysite.com/department > http://www.mysite.com/department/category/ > http://www.mysite.com/department/category/subcategory > http://www.mysite.com/department/category/subcategory/subsubcategory > > Without department path from category to subsubcategory > http://www.mysite.com/category/ > http://www.mysite.com/category/subcategory > http://www.mysite.com/category/subcategory/subsubcategory > > All the rules are written like below > #Rule 1 > RewriteRule ^([A-Za-z0-9-]+)/?$ page1.php?department=$1 [L] > Site Path - http://www.mysite.com/clothing > > #Rule 2 > RewriteRule ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/?$ > page2.php?department=$2&category=$1 > [L] > Site Path - http://www.mysite.com/clothing/women > > #Rule 3 > RewriteRule ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/?$ > page3.php?department=$3&category=$2&subcategory=$1 [L] > Site Path - http://www.mysite.com/clothing/women/sweaters > > #Rule 4 > RewriteRule > ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/?$ > page4.php?department=$4&category=$3&subcategory=$2&subsubcategory=$1 [L] > Site Path - http://www.mysite.com/clothing/women/sweaters/pullovers > > #Rule 5 > RewriteRule ^([A-Za-z0-9-]+)/?$ page5.php?category=$1 [L] > Site Path - http://www.mysite.com/women > > #Rule 6 > RewriteRule ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/?$ > page6.php?category=$2&subcategory=$1 > [L] > Site Path - http://www.mysite.com/women/sweaters > > #Rule 7 > RewriteRule ^([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/([A-Za-z0-9-]+)/?$ > page7.php?category=$3&subcategory=$2&subsubcategory=$1 [L] > Site Path - http://www.mysite.com/women/sweaters/pullovers > > #Rule 8 > RewriteRule ^product/([A-Za-z0-9-]+)/([^./]*)/?$ > product.php?slug=$2&seller=$1 [L] > Site Path - http://www.mysite.com/product/women-pullover-sweater-shirt/ > xyz > > Other Pages Rules except product related > #Rule 9 > RewriteRule ^user/wishlist/?$ wishlist.php [L] > Site Path - http://www.mysite.com/user/wishlist > > #Rule 10 > RewriteRule ^cart/?$ cart.php [L] > Site Path - http://www.mysite.com/cart > > > Conflict occurs between > 1. Rule 1 & Rule 5 & Rule 10 > 2. Rule 2 & Rule 6 & Rule 9 > 3. Rule 3 & Rule 7 & Rule 8 > > How to make uniqueness for each rules so that it hit to specific page and > no conflict occurs. > > > Sincerely > --------------------------------------------------------- > Rajib Karmakar > > Creative Web Logo Technologies > Website: http://www.creativeweblogo.com > Mobile: +919874704940 > Skype: creative.web.logo > © 2008-2018 Creative Web Logo Technologies. >