I’m trying to re-use inputs from a short form field (A) to pre-populate a longer form field (B):
Let’s say a user fills out name and email in form (A) and hits “submit”. He/she then gets redirected to form (B) and sees name and email pre-populated before filling out the remaining prompts.
Is that possible? I assume this can be done with custom code, but would love some help with that.
@Dayna_Lynch yes this can be done, and yes it’s custom code.
It depends a fair bit as well on whether you’re using Webflow’s native forms processor for Form 1, or if you’re using your own ( e.g. a Make.com webhook endpoint ).
Unfortunately there isn’t a “general” solution here, but the approach I’d recommend is;
On Form 1 submit have a handler serialize all of the form data into sessionStorage as JSON so it’s temporarily safe. Your form will submit etc as usual. You can redirect to Form 2 however you like.
Form 2’s page would also have a script that checks sessionStorage for Form 1 data. If it finds it, it will load it, and then map specific fields into Form 2 so the user is ready to go.
Feel free to PM me if you need assistance writing the code for this.