7 Replies Latest reply on Jun 15, 2017 9:52 AM by Ed Rayyis

    Check lead email domain on form if lead is known before executing custom HTML

    Ed Rayyis

      Greetings,

       

      I am creating a 2 step verification, step one check if the lead is known, step 2 If the lead is known then check if their email address is from an accepted domain eg only leads from the domain marketo.com are allowed to proceed.

       

      I started by creating a verification landing page, I created a form and hid the submit button, created a rich text field and set an error message (for unknown and non accepted domain leads). Then in the form settings I selected 'If lead is known' option and in the custom HTML, put a page redirect to the landing page known leads are able to access via a redirect script

      <script>

      window.location.href = "http://www.mydomain.com/welcome.html";

      </script>

       

      My question how do I also check if the known lead is from the accepted domain marketo.com only (via checking the lead's email address) before redirecting them to the welcome page? (my ideal solution)

       

      Second option would be when the form recognises the lead as a 'known lead' it will execute the custom HTML, load the welcome page if your domain is accepted,otherwise load another page say "http://www.mydomain.com/notwelcome.html" instead.