For your specific problem I think you just need to remove the quotes around 'true'. But also look at this link How can I disable an h:commandButton without preventing the action and actionListener from being called?
jsf commandbutton setenabled onclick
-
04-06-2022 - |
Question
how can I disable a commandbutton (ajaxbutton) when the user clicks on it?
i tried it with:
onclick="javascript:this.disabled='true';"
and
onclick="document.getElementById('buttonid').disabled='true'"
but nothing works?
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow