moved ga code to head