WOApplication application = WOApplication.application();
if (!AjaxRequestHandler.useAjaxRequestHandler()) {
application.registerRequestHandler(new AjaxRequestHandler(), AjaxRequestHandler.AjaxRequestHandlerKey);
log.debug("AjaxRequestHandler installed");
}
application.registerRequestHandler(new AjaxPushRequestHandler(), AjaxPushRequestHandler.AjaxCometRequestHandlerKey);
// Register the AjaxResponseDelegate if you're using an ERXAjaxApplication ... This allows us
// to fix some weird border cases caused by structural page changes.
if (application instanceof ERXAjaxApplication) {
((ERXAjaxApplication)application).setResponseDelegate(new AjaxResponse.AjaxResponseDelegate());