4 Replies Latest reply on Apr 5, 2017 12:25 PM by Sanford Whiteman

    Different landing pages based on how many times Leads fill out form

    Bruna Weber

      Hi all,

      Here is a quick explanation of what I'm trying to accomplish:

      I want Leads to fill out a form on our website in order to win a prize. If it's their first time filling out the form, I want them to be redirected to a thank you landing page. If they fill out the same form a second time, I want them to be redirected to another landing page that says they have already entered the contest.

      My question is, is there a way to follow-up with a different landing page based on how many times a person has filled out a form? Thanks in advance!

        • Re: Different landing pages based on how many times Leads fill out form
          Darrell Alfonso

          Hey Bruna,

           

          I'm not sure of how to do this. But if no one else knows, I thought maybe you could do it via confirmation email.

           

          So they will always hit a thank you page that says "confirmation has been sent" and they get that in their inbox.

           

          But if they have already filled out the form they get a different email saying they have already entered the contest.

          • Re: Different landing pages based on how many times Leads fill out form
            Sanford Whiteman

            It's simple to do this at a good-faith level.


            1. Add a score field, in this example Form Fillout Count, to the form as a Hidden field.

             

            2. Add this little bit of Forms 2.0 JS:

             

            MktoForms2.whenReady(function(form){
              var currentValues = form.getValues();
              form.setValues({
                fillCount : parseInt(currentValues.fillCount) + 1 || 1
              });
            });
            

             

            3. Then you can Add Choice on the Thank You page:

             

             

            Now, this isn't a Price Waterhouse-grade secure sweepstakes. A malicious user with mild technical skills can easily tweak their score back to 0. But then again, that same user would probably just sign up with another email alias and/or clear their cookies.

             

            If it isn't clear, the difference between incrementing the score on the client side and bumping it in a Smart Campaign is doing it on the form itself ensures the new value will be available at the time the Thank You Page is decided. On the flipside, it also means you can't stop a person with minor skillz from changing the way the form works. But chances are you aren't validating sufficiently on the back end (very few Marketo users do) for this to be a substantive issue.

            2 of 2 people found this helpful