Visual Form Builder
Request for Google Analytics Event Tracking (3 posts)

  1. Viperior
    Posted 1 year ago #

    I found an old post where someone was asking about this, but the plugin author suggested a workaround. That was at least a year old, however, and I wanted to ask if we could have a solution implemented that would allow us to track events in Google Analytics without having to use a page redirect.

    I know page redirects are one way to do this, but there is a better solution available if we can have a form execute a piece of Javascript code like this when submitted:

    _gaq.push(['_trackEvent', 'Button Clicks', 'Products', 'The blue button on the form page']);

    I am able to do this in the plugin called Contact Forms 7 using the additional settings field at the bottom of any form. Could we get similar support for Visual Form Builder?

    I have a couple forms on the site that are better in VFB, so I don't want to have to abandon the plugin in order to keep getting good marketing data about where conversions are coming from.



  2. Matthew Muro
    Visual Form Builder Pro
    Plugin Author

    Posted 1 year ago #

    If you are executing JS, why not just do that in jQuery?

    The reason you want to use a redirect is because that's the best and most accurate way to ensure you are tracking the events. When using JS you can never be 100% sure. From what I've found online, you'd have to delay the submit action a little bit to make sure the "trackEvent" gets sent.

  3. Viperior
    Posted 1 year ago #

    Thanks so much for replying, Matthew! I'm open to using jQuery, but I could use some guidance on how to do so using VFB. I have only dabbled a tiny bit in jQuery so far. Where should I start in order to set up this kind of solution without requiring additional confirmation pages?

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Visual Form Builder
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic