When I visit my personal site, I append the query string '?ITS_ME' to the URL so I can easily weed out my visits from others when doing stats, etc. It gets tedious to append '?ITS_ME' to every request manually, so I want it to happen automagically using HTTP_REFERER.
For example, I visit the site by manually typing in http://www.mysite.com/?ITS_ME. When I click on the resume link http://www.mysite.com/resume.html, I want it to actually be rewritten as http://www.mysite.com/resume.html?ITS_ME, so it will stand out in the logs.
For the rewrite condition I have:
- Code: Select all
RewriteCond %{HTTP_REFERER} (.*)ITS_ME(.*)
but I can't figure out how to get the RewriteRule to append 'ITS_ME' to the next URL that I click on without the whole URL being replaced and a 'Bad Request' error being generated.
Any ideas?
Thanks!
Bill