I’m trying to dynamically add a field to a form if a radio button value is selected, but am having trouble getting it to work. I’ve tried doing this using EE {if} statements, but I don’t think it’s evaluating the {if} when the Submit button is clicked, only when the template is rendered.
I’ve also tried doing this in Javascript on a form, but the POST contains a hash that a 3rd-party shopping cart service needs to receive and dynamically adding the field via JS causes that hash check to fail once redirected.
Is there a way to run POST/output validation without putting straight PHP in the template? All the validation entries in the Usage guide seem to be explicitly geared towards errors.
I’m still in my noob phase with EE, so any assistance would be greatly appreciated.