I was looking for Javascript support in wget or curl, because I wanted to use them with Google Analytics.

When I was about to give up, I came across this and I found that Analytics is not so complicated and you can use it without Javascript. You don’t even need to look into ga.js or urchin.js. It’s all about an IMG request with the right parameters, something like:

Some parameters are random ids, timestamps, others are about referrer, screen resolution, etc. One easy way to get more details about this is to install Firebug Firefox plugin. Activate the plugin then load a page with Analytics code on it and look for GET requests. You will notice one which goes to www.google-analytics.com. This one is the key and this sends all the information.

You can create this request yourself with wget or curl without any kind of Javascript. Just replace what needs to be replaced. If you like PHP, start with this, it worked for me.

Note: You can use the urldecode() function on the GET request to make it easier to read.