Some refactoring and adding the newest Google Analytics code.