We are using the Wufoo form service to create forms. As such we're using iFrames to inject the Wufoo forms on our site. How can we insert the DTM "appmeasurement" scripts into the Wufoo form's iFrame so that we can collect form related data/analytics?
Please note that due to the fact that we're using a 3rd party service, we do not have the ability to inject any code into the actual Wufoo Form page.
--iFrame Code Example--<iframe height="1195" allowTransparency="true" frameborder="0" scrolling="no" style="width:100%;border:none" src="https://example.wufoo.com/embed/a9a99aaaaaaa999/"><a href="https://example.wufoo.com/forms/a9a99aaaaaaa999/">Fill out my Wufoo form!</a></iframe>
We also have a a means to use javascript
--JavaScript Code Example--
<div id="wufoo-a9a99aaaaaaa999"> Fill out my <a href="https://example.wufoo.com/forms/a9a99aaaaaaa999">online form</a>. </div> <script type="text/javascript">var a9a99aaaaaaa999;(function(d, t) { var s = d.createElement(t), options = { 'userName':'example', 'formHash':'a9a99aaaaaaa999', 'autoResize':true, 'height':'1195', 'async':true, 'host':'wufoo.com', 'header':'show', 'ssl':true}; s.src = ('https:' == d.location.protocol ? 'https://' : 'http://') + 'www.wufoo.com/scripts/embed/form.js'; s.onload = s.onreadystatechange = function() { var rs = this.readyState; if (rs) if (rs != 'complete') if (rs != 'loaded') return; try { a9a99aaaaaaa999 = new WufooForm();a9a99aaaaaaa999.initialize(options);a9a99aaaaaaa999.display(); } catch (e) {}}; var scr = d.getElementsByTagName(t)[0], par = scr.parentNode; par.insertBefore(s, scr); })(document, 'script');</script>