• Resolved Graba11

    (@graba11)


    How can i instert datalayer afret submit i this contact plugin?
    Need something like this: dataLayer.push({‘event’:’contact-form-submitted’});.
    Please help me.

    • This topic was modified 7 years, 2 months ago by Graba11.
Viewing 10 replies - 1 through 10 (of 10 total)
  • Plugin Contributor Form Maker Support

    (@formmakersupport)

    Greetings!

    You can add that Javascript code in Form options > Javascript tab > in the “before_submit()” function.

    Thanks, have a nice day!

    Thread Starter Graba11

    (@graba11)

    Ok, but i need send this after successful submit. Is this possible?

    I have the same issue. I’m trying to figure out how to add a Google Tag manager code snippet into the form so that I can track conversions.

    Thread Starter Graba11

    (@graba11)

    I used Cf7 and it works perfect.

    Plugin Contributor Form Maker Support

    (@formmakersupport)

    Dear @graba11,

    In that case please add your code in the below mentioned function of this “wp-content/plugins/formmaker/js/main_div_front_end.js” file.

    function fm_submit(form_id) {
    jQuery(“#form”+form_id).submit();
    }

    So are you saying I can’t track conversions with Google Tag manager in Form Maker and need to use CF7 to do that?

    Thread Starter Graba11

    (@graba11)

    I said you can use cf7 instead form maker amd do it in cf7 ??

    Plugin Contributor Form Maker Support

    (@formmakersupport)

    Dear @tuffer21,

    If you want to add the Javascript code, which will work during submit, then
    add your code to the below mentioned function of this “wp-content/plugins/formmaker/js/main_div_front_end.js” file.

    function fm_submit(form_id) {
    jQuery(“#form”+form_id).submit();
    }

    Thanks, have a nice day!

    Seems to break the form when I add this. Submit no longer works.

    Plugin Contributor Form Maker Support

    (@formmakersupport)

    Hi!

    We are sorry for the inconvenience you have faced. With a bit detailed information, we might be able to resolve this problem for you. Please open Developer tools of your browser on the page with this issue and look for Javascript errors on Console tab.

    If possible, please send us a screenshot or a copy of the errors you see. I will forward them to our development team and they will suggest a solution as soon as possible.

    Thanks! Have a wonderful day!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Google tag manager datalayer’ is closed to new replies.