I am having issues regarding what I believe to be a problem with
Apache's mod_rewrite capabilities. Specifically what is happening is,
I go to the web page which is applicable to the rewrite rules, and
since the majority of the page is dynamic content, I have noticed that
the script is being executed not once, but three times; I am tracking
this via PHP's error logs. I have also found that if I access the same
page in a format which would not require Apache to apply rewrite
rules, then the script only runs once as I would expect it to. What
could be causing this and is there any way to prevent this from
happening?
My apache version is 2.0.52.
Here are the rewrite rules that I am applying:
RewriteEngine on
RewriteRule ^catalog/(.+) /catalog.php?category=$1
RewriteRule ^(catalog)/?$ /catalog.php
The generally gist of this is to take a page named catalog.php with a
single query string variable and rewrite it like its a directory as to
make it more search engine friendly.
TIA
-Lee