Removed the extra parameter from the attachEvent call, which only takes 2 parameters...