This should help you to use the ActiveCampaign site tracking code to make a cookie association with a visitor from a custom form submission on your website. Before following these steps please ensure you have installed the site tracking code on your site and have whitelisted your website domains accordingly.
Yes, the first is an example of the ActiveCampaign site tracking. You would get this from your dashboard and put this on your page as you would any tracking javascript block (usually before the closing head tag). The second part is an example of how you would use the vgo object in your own client JavaScript to register with ActiveCampaign’s tracking when someone submits your custom form. This part depends on you having a way to hook into the form’s submission event.