Pass UTM parameters to a embeeded typeform in a wordpress page

644 views Asked by At

I have an embedded typeform in a wordpress page. Typeform has hidden fields that can receive information from google analytics. The objective is to receive in the hidden fields of the form the UTM parameters source, medium, campaign, etc that Google Analytics detect.

Typeform support says that that can be done using $_GET[] variable

This is the embedded form i have in my site:

<div class="typeform-widget" data-url="https://form.typeform.com/to/OKA2m2" style="width: 100%; height: 500px;"></div> <script> (function() { var qs,js,q,s,d=document, gi=d.getElementById, ce=d.createElement, gt=d.getElementsByTagName, id="typef_orm", b="https://embed.typeform.com/"; if(!gi.call(d,id)) { js=ce.call(d,"script"); js.id=id; js.src=b+"embed.js"; q=gt.call(d,"script")[0]; q.parentNode.insertBefore(js,q) } })() </script> <div style="font-family: Sans-Serif;font-size: 12px;color: #999;opacity: 0.5; padding-top: 5px;"> powered by <a href="https://admin.typeform.com/signup?utm_campaign=OKA2m2&utm_source=typeform.com-01E5N7Q71GEPVMZ9DXBM39F0A4-professional&utm_medium=typeform&utm_content=typeform-embedded-poweredbytypeform&utm_term=ES" style="color: #999" target="_blank">Typeform</a> </div>

How can i get the UTM parameters ? Any guess?

1

There are 1 answers

0
Josema Gutiérrez On

They have an attribute to embed forms to pass get parameters, I haven't tested already:

data-transferable-url-parameters="utm_source, utm_medium"

Here you have another similar answer at their forum: https://community.typeform.com/integrate%2Dyour%2Dtypeform%2D43/how%2Dto%2Dknow%2Dthe%2Dgoogle%2Dkeywords%2Deach%2Dresponse%2Dcame%2Dfrom%2D573