chrome removed beforeload event handler - only use it on Safari