I'm using mod_rewrite to place a category title within the URL, like locahost/categoryName in addition to a location localhost/categoryName/locationName .

One question I'd, and I am sure it's not hard to do like a rewrite rule, is how do i allow it to be to ensure that the rule doesn't affect some specific directory, like: localhost/admin . For the reason that situation I would like it to visit the bodily directory.

Thanks

Get this to the first rule:

RewriteRule localhost/admin - [L]

Which means: match localhost/admin, do nothing at all, last rule (only when matched up).