4 Replies Latest reply on Feb 13, 2012 1:04 PM by flavioeasy

    a4j:commandButton doesn't get mouse click on firefox

    flavioeasy

      Hi all,

      I think this is very strange.

      I have a popupPanel with few fields and a a4j:commandButton to submit the form.

      I tried on IE and everything works fine.

      I tried on firefox (9.0.1) and when I click on the button nothing happens ; if I move with arrow keys to the button and than push enter it works fine.

      I investigated the code but I cannot see anything.

      I run with RF 4.1 on tomcat 6.

      Can somebodi help me.

      Thanks a lot.

      Flavio

       

      Here is the code

       

      <ui:composition xmlns="http://www.w3.org/1999/xhtml"

                      xmlns:h="http://java.sun.com/jsf/html"

                      xmlns:f="http://java.sun.com/jsf/core"

                      xmlns:a4j="http://richfaces.org/a4j"

                      xmlns:ui="http://java.sun.com/jsf/facelets"

                      xmlns:es="http://java.sun.com/jsf/composite/esutils"

                      xmlns:rich="http://richfaces.org/rich"

                      xmlns:richext="http://java.sun.com/jsf/composite/richext">

          <rich:jQuery query="focus().select()" selector="#ESSocEditPanelGrid :input:visible:enabled:first" name="focusFirst"/>

          <h:form id="ESSocEditPanelForm">

              <rich:popupPanel id="ESSocEditPanel" autosized="false" keepVisualState="false" domElementAttachment="parent"

                               width="720" height="225" headerClass="panel-header-class" resizeable="true" onshow="focusFirst();">

                  <f:facet name="header">

                      <h:outputText value="#{eSSoc.headerEditPanel}"/>

                  </f:facet>

                  <f:facet name="controls">

                      <es:esUtilClosePanel varAction="#{rich:component('ESSocEditPanel')}.hide();"/>

                  </f:facet>

                  <h:panelGroup layout="block" styleClass="scrolls">

                      <a4j:outputPanel id="ESSocTableMod" >

                          <h:panelGrid columns="2" id="ESSocEditPanelGrid">

                              <h:outputText value="#{mess.labelSocId}"/>

                              <h:outputText value="#{eSSoc.ESSoc.a2id}" rendered="#{!eSSoc.insert}"/>

                              <h:inputText id="a2id" value="#{eSSoc.ESSoc.a2id}" size="7" required="true"

                                           maxlength="7" requiredMessage="#{mess.errSocId}" rendered="#{eSSoc.insert}" >

                                  <f:validateLongRange minimum="1" maximum="9999999" />

                              </h:inputText>

                              <h:outputText value="#{mess.labelSocDes}"/>

                              <h:inputText id="a2deso" value="#{eSSoc.ESSoc.a2deso}" size="100"

                                           required="true" requiredMessage="#{mess.errSocDesc}" />

                              <richext:spacer height="5" width="20" />

                              <richext:spacer height="5" width="20" />

                              <h:outputText value="#{mess.labelUserIns}"/>

                              <h:outputText value="#{eSSoc.ESSoc.a2usin}" />

                              <h:outputText value="#{mess.labelDataIns}"/>

                              <h:outputText value="#{eSSoc.ESSoc.a2dtin}" >

                                  <f:convertDateTime pattern="dd-MM-yyyy HH:mm:ss" timeZone="#{esUty.curTZ}" />

                              </h:outputText>

                              <h:outputText value="#{mess.labelUserVar}"/>

                              <h:outputText value="#{eSSoc.ESSoc.a2usva}" />

                              <h:outputText value="#{mess.labelDataVar}"/>

                              <h:outputText value="#{eSSoc.ESSoc.a2dtva}"  >

                                  <f:convertDateTime pattern="dd-MM-yyyy HH:mm:ss" timeZone="#{esUty.curTZ}" />

                              </h:outputText>

                              <a4j:commandButton action="#{eSSoc.confirmData}" render="ESSocTable"

                                                 oncomplete="if (!ajaxRequestContainsErrors()) #{rich:component('ESSocEditPanel')}.hide();"

                                                 image="/resources/images/check.png" title="#{mess.tipConferma}"/>

                          </h:panelGrid>

                      </a4j:outputPanel>

                  </h:panelGroup>

              </rich:popupPanel>

          </h:form>

      </ui:composition>