2 Replies Latest reply on Aug 25, 2008 12:12 AM by Lincoln Baxter III

    a4j:form does not submit with enter key in IE6/7, works fine

    Lincoln Baxter III Master

      Hi, I've got a form that takes input from one field and then re-renders itself.

      In FireFox this works fine, the user can press return in the input box or click the submit button and all ajax events work fine... but in IE6/7, the user must click the button.

      If they press return in IE6/7, A4J does Validation (error messages show up with bad input), but no submit/action method is called if the input passes validation.

      How do you fix this? Did I do something wrong? Thanks,

      a4j:form id="storyform" reRender="storyform" ajaxSubmit="true" ajaxSingle="true">
      
       <div class="centered" id="story"><span><h:outputText
       value="... " /></span><c:forEach items="#{storyBean.current}"
       var="chunk">
       <span><h:outputText value="${chunk} " /></span>
       </c:forEach><span><h:outputText value="..." /></span></div>
       <div class="clearing"></div>
      
       <div class="centered" id="contribution"><h:message
       showSummary="true" showDetail="false" for="input"
       style="color: red;" /><br />
       <h:inputText id="input" autocomplete="off"
       value="#{storyBean.input}"
       validator="#{storyBean.validateContribution}" required="true" />
       <h:commandButton id="submit" action="#{storyBean.addContribution}"
       value="submit" /></div>
      </a4j:form>


      I've tried an <a4j:commandButton> as well, but still no luck.