0

I have the below code in my JSF page for a button.

<h:commandButton title="#{msg['dealsheet.button.accept']}"
styleClass="btnIcon iconDSAccept jqTooltip iconDSAcceptNPD"
onclick="return checkForPopup(this,'#{ds.dealSheetType}','#{ds.dealSheetNo}');"
action="#{dealSheetBean.saveDealSheetOnOverWrite()}"
actionListener="#{dealSheetBean.assignSelectedDeal(ds.dealSheetNo)}">
</h:commandButton>

It was working fine previously. But after adding the attribute id="iconDSAccept#{ds.dealSheetNo}" to h:commandButton the button is not working on the first click i am getting log as 12:55:27,144 WARN [org.apache.tomcat.util.http.Parameters] Parameters: Invalid chunk ignored.. When I click for the second time it is working fine.

Can anyone advice me why this is happening and how to resolve this ?

Aravind
  • 1,145
  • 6
  • 18
  • 44
  • The problem is with the text **#{ds.dealSheetNo}**. After removing this, the button is working fine. :) But I don't know why it is not working on the first click with this code snippet. If someone knows the answer, please post it. – Aravind Jan 20 '17 at 04:21
  • what is the reason you are generating dynamic id is this inside some loop? – Subodh Joshi Jan 20 '17 at 05:24
  • @SubodhJoshi Yes. The code is inside a loop. Inside the tag **ui:repeat** – Aravind Jan 20 '17 at 06:04
  • As you dont tell what exactly your code look like .Please check Point 9 of this question's answer http://stackoverflow.com/questions/2118656/commandbutton-commandlink-ajax-action-listener-method-not-invoked-or-input-value/2120183#2120183 – Subodh Joshi Jan 20 '17 at 06:42

0 Answers0