added google analytics function