Strange mod_rewrite problem - willing to pay for help.

Discuss practical ways rearrange URLs using mod_rewrite.

Strange mod_rewrite problem - willing to pay for help.

Postby Bigtime » Fri Feb 11, 2011 10:03 pm


Here is my rule:

Code: Select all
RewriteRule ^[^/]+/([^/]*)/([^/]*)\.php$ /review_single.php?item_id=$1&id=$2 [L]

Original URL:

Code: Select all

Rewritten URL:
Code: Select all

The word chilis is a category that gets pulled from the database.


That works great but there's a part of the website that will only work if I put a forward slash at the beginning changing it to this:

Code: Select all
RewriteRule ^/[^/]+/([^/]*)/([^/]*)\.php$ /review_single.php?item_id=$1&id=$2 [L]

BUT when I do that, it breaks another part of the site.

How do I rewrite that so that one area of the site will work with the '/' and the other part will work without it?

Thanks in advance,

Posts: 4
Joined: Mon Nov 24, 2008 11:50 pm

Return to Friendly URLs with Mod_Rewrite

Who is online

Users browsing this forum: No registered users and 5 guests