I have multipage webform. I want to compute the value of the component (Hidden -type) which is on the second page based on the data submitted on the first page.
I'm using hook_form_alter
and added my client_submit
handler:
function mymodule_client_submit(&$form, &$form_state)
I can read there submitted data from the first page and I can do the calculation. But I cannot set the value of the component from the second page. I can see the structure of the form in $form
or $form_state
parameter. But I do not know how to set the value of the component from the second page as it was not submitted yet.