Closed

Trying to setup Google Tag Manager

This project received 4 bids from talented freelancers with an average bid price of $88 USD.

Get free quotes for a project like this
Employer working
Skills Required
Project Budget
N/A
Total Bids
4
Project Description

Hi,

I am trying to configure the new Google Tag manager on my site.

I am not sure if the problem lies with the code or with my setup.

Reason why I think it might be the code, I have had to place it within a PHP echo. I know the echo is loading at the right time but I am not sure if the code will still work after I had to add in / to let the ' work see below (changed my ID to XXXX for security):

echo '<!-- Google Tag Manager -->

<noscript><iframe src="//[url removed, login to view]"

height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'[url removed, login to view]':

new Date().getTime(),event:'[url removed, login to view]'});var f=[url removed, login to view](s)[0],

j=[url removed, login to view](s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=

'//[url removed, login to view]'+i+dl;[url removed, login to view](j,f);

})(window,document,'script','dataLayer','GTM-XXXX');</script>

<!-- End Google Tag Manager -->

';

The original code Google tag manager gave me was:

<!-- Google Tag Manager -->

<noscript><iframe src="//[url removed, login to view]"

height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>

<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'[url removed, login to view]':

new Date().getTime(),event:'[url removed, login to view]'});var f=[url removed, login to view](s)[0],

j=[url removed, login to view](s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=

'//[url removed, login to view]'+i+dl;[url removed, login to view](j,f);

})(window,document,'script','dataLayer','GTM-Q285');</script>

<!-- End Google Tag Manager -->

Or it could be the setup on my Google Tag manager account, can give you access to this.

Thanks.

Looking to make some money?

  • Set your budget and the timeframe
  • Outline your proposal
  • Get paid for your work

Hire Freelancers who also bid on this project

    • Forbes
    • The New York Times
    • Time
    • Wall Street Journal
    • Times Online