Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #1138971

    I am sorry to ask this question after seeing all of the threads about this topic. It seems that what one moderator is saying is that I can place all the Google scripts, such as Google Analytics script and the Google Adwords script together into the Enfold > Google Services > Google Analytics Tracking Code field and Enfold will wrap them together. That is, it seems the Enfold > Google Services > Google Analytics Tracking Code function is equivalent to the Google Tag Manger for Enfold. It seems you are saying I do not need to be concerned about the Google Tag Manager.

    Two questions:
    1) Is it correct to conclude that I do not need to be concerned about placing Google Tag Manger scripts into the header and then one into the body?
    2) Can I add Google Analytics, Google Adwords and Google Ad Conversion tracking scripts into the Enfold > Google Services > Google Analytics Tracking Code field and Enfold will correctly combine them? Or, will Enfold just process the three scripts separately?
    3) If Enfold will just process the scripts separately, then can I add the Google Tag Manager script which is designed for placement in the body into the functions.php file?

    Thank you

    #1139409

    Hey John,

    Placing scripts in the Google Analytics box will add them to the head section of your site, on every page. If a script should not work or if something else needs to be added somewhere else then you will likely need a function in order to add it properly. If that should be the case for you then just let us know which code you need to add and where.

    Best regards,
    Rikard

    #1139754
    This reply has been marked as private.
    #1140566

    Hi,

    Please try this in your functions.php file:

    function envatojlc_add_gtm(){
    ?>
    <noscript><iframe src=”https://www.googletagmanager.com/ns.html?id=XXXXXXXXXXXX”
    height=”0″ width=”0″ style=”display:none;visibility:hidden”></iframe></noscript>
    <?php
    }
    add_action('wp_body_open', 'envatojlc_add_gtm');

    Make sure that you are on the latest version of the theme and WordPress, otherwise it might not work.

    Best regards,
    Rikard

    #1140567

    Hi,

    Also please change all instances of

    and

    to

    "

    Best regards,
    Rikard

    • This reply was modified 5 years, 3 months ago by Rikard.
Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.