correcting ajax hook for analytics