Business email validation

Please note that the snippets in this article will only work for pages using the new and improved page generator, the Thor Rendering Engine. We recommend testing the snippet functionality in case your page was created before 2019 or duplicated from an older page, as the two render engines have a different code structure in the backend. To migrate your older pages to the new Thor Rendering Engine, you can contact our support team at help@instapage.com.

If you have a lead capture form that asks for the visitor's email address and you want to only receive business emails, you can implement the snippet below on your page.

Add the code below in the Javascript - Footer section of the page editor:

You will need to edit the highlighted sections below to contain the exact name of your field and the desired error message that will be shown to visitors who enter a non-business email address. Make sure that you leave the single quotes at the beginning and end of the text that you replace.

bev2_copy.png

If your field is named exactly Email you can leave the code unaltered, but if it is named "E-mail", "Email address", "E-mail address", or if it is in a different language (e.g. "Correo electronico"), you will need to add the exact name of your field in the code, on the fifth row, in order for it to work.