Support » Plugins and Hacks » Google Adwords Conversion Code & Gravity Forms

Google Adwords Conversion Code & Gravity Forms

  • Hi there, I have looked everywhere to find the answer to this so hoping you can help?

    I need to put the google adwords tracking code on the conversion page on my gravity form (plugin).

    So for instance, if someone fills a contact form and a pop up box says ‘thanks’ – thats where I need to put the code.

    I cant find how to do that and I not skilled enough to mess with the ftp.

    Thanks for your help -in anticipation…

Viewing 2 replies - 1 through 2 (of 2 total)
  • You might want to take a look at this (using Google Analytics events)


    Add this below to your functions.php file and change the $form[‘id’] to your form ID #. Obviously, you can change the Event name sent to Google Analytics.

    add_action("gform_post_submission", "gf_ga_tracking", 10, 2);
    function gf_ga_tracking($entry, $form) { 
        if($form['id'] != 4) return; ?>
        <script type="text/javascript">
            jQuery(document).ready(function($) {
                _gaq.push(['_trackEvent', 'Forms', 'Submission', 'GA Testing Form FINAL']);
        <div class="ga-confirmation">Nice! Your <strong>successful</strong> form submission was recorded by Google Analytics.</div>
    <?php } ?>

    Thanks for that. Sorry for the slow response. I have been ill.

    The link seems to go to a closed forum.

    Will that code track the conversion (ie. the completed and sent form) or just a visit to the form page.


Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Google Adwords Conversion Code & Gravity Forms’ is closed to new replies.
Skip to toolbar