1 Reply Latest reply on Aug 22, 2017 9:54 AM by Sanford Whiteman

    Filtering based on character count

    Micaela Wright

      We'd like to do some filtering based on the character count of a field. For example, a person on our website fills out a form. If the "details" field is less than 10 characters, they are not qualified to talk to our sale team. We'd like to route it to support instead. Is there a way to do this within Marketo? Ideally we could do this using an "Add Choice" step.

        • Re: Filtering based on character count
          Sanford Whiteman

          Natively in a Smart List, no. But on the form side, sure:

           

          MktoForms2.whenReady(function(form){
            form.onSubmit(function(form){
              form.addHiddenFields({
                meetsMinDetails : form.getValues().Details.length >= 10 ? 'yes' : 'no'
              });
            });
          });
          

           

          (meetsMinDetails is a Boolean field in your instance.)

           

          Or you could use a webhook on the server to check.

           

          You could also set a min/max on a textarea field itself, but that might telegraph your rules too much. You want the person to organically have more to say.