Adding Checkboxes to an Form to Tag Subscribers
Checkboxes correspond to Tags in your account. When checked during the subscription process, the subscriber will have those tags applied to them.
Note: This article is for Old Forms (Forms created before July, 2018). The current Form designer has checkboxes built in.
This is also a great option for GDPR consent. → Click here to read more about that.
Here is an example of what we will be achieving in this article:
In this article, we'll map the 2 checkboxes to 2 different Tags in your account so that when a subscriber checks a checkbox, they will be added to the appropriate Tag.
Get Your Tag's ID Number
We've created 2 Tags for this tutorial, " Interested in cool widgets", and, "Gave consent to subscribe".
- Go to the Subscribers page.
- Click Create a Tag in the right-hand menu, or use your already-created Tag. This is under "Add Subscribers" and below your Segments.
- Go into your Tag and you will see a list of subscribers who have this Tag.
- Copy the 6 digit Tag ID found in the URL in your browser's address bar.
- Example: https://app.convertkit.com/subscribers?subscribable_ids=480189&subscribable_type=Tag&tag=480189
- In this case, the Tag ID for our Tag "Interested in cool widgets" is 480189.
- Copy your Tag ID and set it aside where you can access it in a moment.
Repeat this process for additional Tags you want checkboxes for.
Modify Your Form's HTML
- Go to the Forms page.
- Click on your Form you'd like to add checkboxes to.
- Head to the Settings tab, then click the Embed tab on the left-hand side.
- Select Raw HTML.
- Copy the entire HTML and paste into a text editor, word document, or onto your website.
- The HTML cannot be altered within the app, so it is necessary to copy it and edit it elsewhere.
- Above the
<button>element in the HTML, insert the code below (this code will render the checkboxes, right above the submit button on the form).
<!-- Begin Checkboxes --> <div class="ck_control_group"> <label style="display: block; margin-top: 10px"> <input type="checkbox" name="tags" value="480189" /> I'm interested in cool widgets </label> <label style="display: block; margin-top: 10px"> <input type="checkbox" name="tags" value="480191" /> I'm giving consent to subscribe </label> </div> <!-- End Checkboxes --><br>
7. Replace the Tag IDs above with the Tag IDs you copied from the URL of your Tag(s).
That's it! Now you can embed the HTML on your site and have beautiful, functioning checkboxes!