Apply tracking code