Skip to main content
Catherine_Dalm2
Level 2
Jun 12, 2020 2:09 AM UTC
Question

Can I create a cap on how many values can be picked for a multi-select?

I have a form on a landing page.  I am giving the lead the ability to multi-select for a particular field but I want to limit the amount of values that they can select.  The field has 40 values but I want to limit them to just pick 3.  Is there a way that I can do this?

3 replies

SanfordWhiteman
User Group Leader
User Group Leader
Jun 12, 2020 4:50 AM UTC

Before I answer, you're using the true <select multiple> type (not checkboxes)?

Translate
Catherine_Dalm2
Level 2
Jun 17, 2020 8:20 AM UTC

Hi.  Yes, the field type on the form is select and I have multi-select checked.

Translate
SanfordWhiteman
User Group Leader
User Group Leader
Jun 18, 2020 4:29 AM UTC

Like so:

 

MktoForms2 :: <select multiple> Min/Max Checked v1.0.0

 

Just put the code from the JS pane inside a <script>. On a Marketo LP, put it right before the closing </body>. If you're using the embed code, put it anywhere after the embed code.

Translate