Recording Ad Source via Hidden Field
Posted: Sat Jul 12, 2025 5:45 am
Let’s say you have a marketing campaign running for 3 months, with a new ad released each month. The goal of this campaign is to see which ad brings in the most leads so your future campaigns can focus on such advertisements to yield the best results. To show the steps for this example, we will have the following query string parameter of “?ad=[source]”. The values in this example will be fb or ig . The url will look something like this: depending on the ad source, the parameter value with be different.
The process is very similar to the above section “Autofilling Parts of a Form,” except entrants don’t need to see, nor have access to alter, the ad source field. How do we do this? By making a hidden field. You will still see the phone number lead data once you export the entries, but the people entering the form will have no idea that data is even there. Let’s dive in.
Once your URL is set up properly, open your campaign in ShortStack’s builder. In your form, add a text field. Title this something like “ad source”. Check the box that says “Make this field hidden”. By checking this box, the field will not be visible in the form but will still collect information.
The process is very similar to the above section “Autofilling Parts of a Form,” except entrants don’t need to see, nor have access to alter, the ad source field. How do we do this? By making a hidden field. You will still see the phone number lead data once you export the entries, but the people entering the form will have no idea that data is even there. Let’s dive in.
Once your URL is set up properly, open your campaign in ShortStack’s builder. In your form, add a text field. Title this something like “ad source”. Check the box that says “Make this field hidden”. By checking this box, the field will not be visible in the form but will still collect information.