I have a relatively complex form submission logic that I am trying to create and I am pretty stuck right now.
General explanation:
I am using Webflow together with Make for automation.
What do I currently have?
Set up From in webflow
On form submission → Make takes the inputs, filters them, has some calculations made, creates a new CMS item based on the outputs and publishes the new page.
At the same time, after submitting the form, the user is being re-directed to a “loading” page.
I am now trying to get the URL of the new CMS item so that I can redirect the user to the newly created page from the “loading” page. (The loading page is not necessary, if it’s easier to re-direct the user to the custom CMS item directly)
So essentially the user should be re-directed in one way on another to their custom offer page after form submission.
I have tried different solutions already but none of them worked. I have the code to re-direct the user to a page I set, but I have no idea how to fetch the newly created URL for the user who submitted the form
Could anyone suggest a solution using Webflow and/or Make for this? I am not sure how to approach this at the moment
Any help would be appreciated!
Side note: I am also using Inputflow for conversational form style on Webflow which works for me so far.
In this situation, I use a Make webhook as the trigger to initiate the automation, and the Webflow form calls that directly.
Once the automation is completed, use a webhook response element in Make to return the data you want, success/fail, your CMS item slug, etc.
On the Webflow side you’ll need to handle the form submission manually with JS - send the form to the make webhook, wait for the response, and then decide what you want to do base on the response. For you this is probably to redirect to the relevant collection page.
Note you need to be careful with the item creation process; the item must be created and published “live” in order for it to exist when you redirect- but Webflow has some situations in which the “live” step will fail and may even fail silently with no error. This seems to happen when staging and production CMS schemas are out of sync.
I’d recommend you add some safeguards in your code to handle this possibility.
Thank you for your help!
I seemed to have also found a guide specifically about what you talk about.
I have followed the guide but it still seems to not work. Instead of redirecting me to the correct CMS item URL, it re-directs me to the Make webhook URL. (I see the data returned to me from the webhook so:
I have found a solution - there was a small mistake in the guide.
In the Make scenario my headers should be:
Key: Location
Value: {New Url} - needing to input the new URL of the CMS which you can get through the process in Make
In the webflow form, removing the redirect field. Then everything else according to the guide works :)