0

I'm trying to send the value of the element to the back-end ManageBean for example I have the below button :

<p:commandButton action="#{serviceBean.insertSubscriberPinCode() class="Regest" 
                        value="CONFIRM">
</p:commandButton>

if I want to catch the element using javascript it will be done as shown below :

<script>
var button = document.getElementsByClassName("Regest")[0];
</script>

my question is how could I send the value of the var button to my bean?

BalusC
  • 1,040,783
  • 362
  • 3,548
  • 3,513
yasmin
  • 5
  • 2
  • somehow, but I tried it it doesn't work, I need to pass the value of the button to the back-bean, the value of the button is what I can get from getElementsByClassName – yasmin Sep 07 '21 at 13:02

0 Answers0