Hi all,
I have a <cms:form> with a default set of fields.
The form has a button enabling the submitter to add addtional fields (basically it adds a set of definid fields everytime the user hits the button). This is done by using Javascript and appending the fields within the form.
All fields are correctly submitted when I read the $POST variable from PHP directly.
However, when displaying error fields the newly added fields are not shown (probably because at the time the page loads the fields do not yet exist).
What i have done so far is to have a hidden field showing how many imes the button was pressed and then calling the Javascript-addFields functions so many times to get the fields back.
Now I'm missing the part how to get correct error messages (all fields have unique IDs and names) and prefill the values.
Any ideas?
Thanks!!
Patrick
I have a <cms:form> with a default set of fields.
The form has a button enabling the submitter to add addtional fields (basically it adds a set of definid fields everytime the user hits the button). This is done by using Javascript and appending the fields within the form.
All fields are correctly submitted when I read the $POST variable from PHP directly.
However, when displaying error fields the newly added fields are not shown (probably because at the time the page loads the fields do not yet exist).
What i have done so far is to have a hidden field showing how many imes the button was pressed and then calling the Javascript-addFields functions so many times to get the fields back.
Now I'm missing the part how to get correct error messages (all fields have unique IDs and names) and prefill the values.
Any ideas?
Thanks!!
Patrick