Object unterstützt diese Eigenschaft oder Methode nicht mit einer Primefaces-Omnifaces-Timeout-Kombination

Setup: JSF, PrimeFaces 3.2, Omnifaces 1.1, JBoss AS 7.1.1, Final, Mojarra 2.1.7

Ich habe eine einfache Seite (unten aufgeführt) und Omnifaces eingerichtet, um mit ViewExpiredExceptions für Ajax-Aufrufe umzugehen. Wenn die unten aufgeführte Seite abläuft und ich im IE8 auf eine Schaltfläche für Primefaces (Ajax) klicke, wird die abgelaufene Fehlerseite angezeigt, jedoch mit dem folgenden Javascript-Fehler:

Meldung: Objekt unterstützt diese Eigenschaft oder Methode nicht. Zeile: 1 Zeichen: 5500 Code: 0 URI: bla bla / mywebapp / javax.faces.resource / primefaces.js.xhtml? Ln = primefaces & v = 3.2

In anderen Browsern scheint dies keinen Fehler zu verursachen.

Meine Seite (home.xhtml):

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    template="/WEB-INF/templates/layout.xhtml"> 
    <ui:define name="body">
        <h:form id="form_search">
            <p:commandButton id="idbtn1"
                actionListener="#{bean.doSomething}"
                value="Do something (ajax)!">
            </p:commandButton>
            <p:commandButton id="idbtn2" ajax="false"
                actionListener="#{bean.doSomething}"
                value="Do something!">
            </p:commandButton>

        </h:form>
    </ui:define>
</ui:composition>

Die Timeout-Fehlerseite: expired.xhtml

<ui:composition xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    template="/WEB-INF/templates/layout.xhtml">
    <ui:define name="body">
    Your session has timed out.
    </ui:define>
</ui:composition>

Die Vorlage layout.xhtml

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
"http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
        xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:ui="http://java.sun.com/jsf/facelets">

<f:view contentType="text/html">
    <h:head>
        <f:facet name="first">
            <meta http-equiv="X-UA-Compatible" content="IE=edge" />
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
            <meta http-equiv="Cache-Control" content="no-cache, no-store, must-    revalidate" />
            <meta http-equiv="Pragma" content="no-cache" />
            <meta http-equiv="Expires" content="0" />
        </f:facet>
        <base href="${facesContext.externalContext.requestContextPath}" />
    </h:head>
    <h:body>
        <ui:insert name="body"></ui:insert>
    </h:body>
</f:view>
</html>

Web.xml hat unter anderem:

    <error-page>
        <exception-type>javax.faces.application.ViewExpiredException</exception-type>
        <location>/WEB-INF/errorpages/expired.xhtml</location>
    </error-page>

    <filter>
        <filter-name>facesExceptionFilter</filter-name>
        <filter-class>org.omnifaces.filter.FacesExceptionFilter</filter-class>
    </filter>
    <filter-mapping>
        <filter-name>facesExceptionFilter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>

Wenn ich nach Ablauf auf die zweite Schaltfläche klicke, wird die abgelaufene Seite ohne Javascript-Fehler angezeigt.

Irgendwelche Ideen?

Antworten auf die Frage(1)

Ihre Antwort auf die Frage