revision to global ajax event handling