Domain Fwd + Stats


My goal is to track traffic being sent through a forwarded domain to an affiliate link.

So:
Domain1.com has a link to MyDomain.com.
MyDomain.com is then forwarded to Domain2.com.

I want to count all traffic sent through MyDomain.com. Traffic stats must include daily visitors by country. Note that I have no control over the code on Domain1.com or Domain2.com. I am not looking for a brand new statistics script, just incorporation of something that is existing.

- A 301 redirect at MyDomain.com + stats is ideal, however a Meta Refresh or Javascript redirect is an ok solution also. (If this is the solution that has been selected, code must be included to redirect browsers with Javascript disabled to the same forwarding address.)

- Reporting must include: Daily visitors broken down by country.(Google Analytics would be ideal.)

The obvious simple solution is to copy and paste Google Analytics code onto a page that has a meta refresh. This does not work (try it and see). However, if you can get this working, then that is the kind of solution I am looking for. Alternatively if you know an existing free open source server side application that I can use to solve this, then that is fine also.

Find a Programmer to create a similar project!