Ad trackers p1.1

This is the rebased and extended version of pullrequest #391