This discussion is archived
0 Replies Latest reply: Jul 15, 2013 5:59 AM by 56e5a93f-5619-4bc5-89ba-9611bb480b91 RSS

h:inputtext not working with multiple forms in JSF2.2

56e5a93f-5619-4bc5-89ba-9611bb480b91 Newbie
Currently Being Moderated

h:inputText is not working in the latest JSF2.2 with multiple forms. I have 2 forms

form1 have: one command button and one input text

form2 has: one input text and one output label

on click of command button in form1, i am rendering the form2(both outputlabel and input text).

but only output label is rendered properly with correct values (corresponding getter method gets called and value is displaying) but the input text is not calling the corresponding getter method hence showing null.

Note: we noticed this issue only if we use multiple forms, within single form its working fine. also it worked fine in JSF2.0

Version used: JSF api - 2.2 (com.sun.faces) JSF impl - 2.2 (com.sun.faces)

let me know if anyone have solution to handle this.

the forms are not nested and both the beans are in View scope.  


<h:form id="form1" prependId="false">
<a4j:commandLink id="actionEdit" title="Click" action="#{bean.action}" 
render="paymentInstructionDetail" styleClass="iconLarge edit" />
</h:form>

<h:form id="form2" prependId="false">
  <a4j:outputPanel ajaxRendered="true" id="paymentInstructionDetail">
  <h:inputText value="#{bean1.amount}" id="sample"/>
  <h:outputLabel value="#{bean1.amount}" id="sampleLabel"/>
 </a4j:outputPanel>
</h:form>




Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points