@Maha89 wrote:
Thank you for your reply Darhil,
- I have 5 required fields in the form now, and I want to add a Required extra field in Progpro while keeping the number of fields at 5 all the time, that's why I want to hide that 6th field in case the visitor previously filled it out, does this make sense? Is this even possible? so basically gathering extra required info while keeping the form short (5 fields)
That's the basic use-case of ProgPro feature, showing user fields that they haven't filled at the same time keeping the form length short (under-control, not exceeding a set # of fields)! Also, a known visitor is not shown the ProgPro fields that they've already filled on the form. You can add the new field in the ProgPro, and set the "Number of Blank Fields" appropriately so that at a time only 5 fields are shown to the visitor. If you have x non-progpro fields (i.e., fields added of outside the ProgPro section), then you need to set the "Number of Blank fields" properties in the progpro section to 5-x. This would ensure that total number of fields including non-progpro fields don't exceed 5 fields at any time. You can make the progpro fields required, as I said earlier they won't prevent any form submissions if they aren't shown on to visitor on the page in the first place.
- Can you please share the script that could help make non-required fields required in Progpro if you have it? I will need it because I want to use required fields in the Progpro and prevent the visitor from submitting the form unless they provide that info?
You can refer Sandy's codepen for the script, you may need to make few adjustments, but should be enough to give you an idea on how to make optional fields required using JS. Also, as I said earlier, you can make progpro fields required from the form editor itself (that'd be much simpler!)