Want to redirect customers to another page on your Magento 2 website after form submission? With Blue Form Builder, this is extremely simple. In this article, we will show you 2 ways to redirect users to your wanted page after they submit a form.
*Note: Before starting, you first need to install Blue Form Builder. Then, have a form created. (You can look at 5 steps to create a Magento 2 contact form as an example). Also, make sure that you know the page URL you want to redirect customers to.
Redirect all customers on submission
To redirect every customer after they submit the form, you can follow these steps:
- Open your wanted form in the backend. Then open Settings > Advanced.
- Enter the page URL you want to navigate users to in Redirect on Submit field. Use “/” to let them stay on the same page after form submission.
- Decide after how many seconds that customers will be redirected in Redirect X seconds after form submit field.
Remember to save your settings after finishing.
Note: This function of redirecting customers after submission is related to the Footer Content in success message (Open Settings > Success Message)
Only when you fill out Redirect on Submit and Redirect X seconds after form submit fields will the footer content appear in success message on frontend.
If you enter [redirect_time] variable in Footer Content, it will be replaced with the value filled in Redirect X seconds after form submit with redirect countdown.
If you enter [redirect_link] variable, it will be replaced with the link filled in Redirect on Submit.
Redirect customers based on their input
For this function, you need to install Smart Conditional Logic plugin that will then be integrated with Blue Form Builder.
By using this plugin, you can redirect certain customers based on what they fill out. Let’s look at how to do it:
- Open Plugin tab, then open Conditional Form Fields. Click “ADD NEW LOGIC” to start setting up the logic.
The logic we want to take as example is that: the form has “What are you having issues with?” field with 4 options. If users choose “Computer” option, they will be navigated to the page “http://blueformbuilder.m2.magezon.com/computer-issues” after form submission.
You have to set both the condition and action for the logic.
- First, set the condition by clicking on “ADD CONDITION ROW”. In the first box, choose the wanted field from a drop-down list (in this example, we choose “What are you having issues with?” field). In the second box, choose the condition (we select “is equal to”). Then enter the value for the conditional field in the final box (we enter “Computer”). The condition will be like this:
- Second, set the action by clicking “ADD ACTION ROW”. Choose action “redirect to” in the first box. Enter the page URL you want to redirect users to in the second box, like this:
Now you’ve finished setting up the logic. Remember to save the logic. You can test how it works by trying submitting the form.
In this article, we’ve looked at 2 ways to redirect customers to another page after a successful submission. You can configure in the form settings to apply to any customers who submit the form successfully. Or use our Smart Conditional Logic plugin to redirect certain users based on their form input. So why not try by yourself and let us know your opinion?
Try FREE Blue Form Builder demo today
Create whatever type of Magento form in any style you want just in minutes. Just by drag & drop.