Google Analytics on DW Template

5 replies
  • WEB DESIGN
  • |
Hi,

I've built my site using a Dreamweaver CS4 template and I'm trying to add Google Analytics code to it but it won't let me do it. It's been awhile since I've worked on this site so I'm a little rusty on how to do it.

You have to add the code immediately before the /body but all that code is "gray" on my page template and when I click on it to change it, it just goes "bing". I know this is probably something simple I'm doing wrong. Anyone got any ideas?

Thanks for your help!
#analytics #google #template
  • Profile picture of the author Richard Whyte
    Yes...

    I have seen this before when you copy a page off of the internet and save it to your system...

    Basically it is saying that you are not allowed to edit the page and the code in DW is gray colored.... Right?

    What you need to do is look at the code and see a section that is commented out... The page may have a couple of sections like this... I don't remember the exact words, but is will say something about no edit or Something Edit....

    What you need to do is open the page in Windows notepad... Delete those lines and save it then reopen in DW.... Now you can edit that section...

    Scroll down in the code and see if you have more of these...

    You may need to do this a couple times.

    NOTE... NOTE... Note!!!!!!!!!!!!

    Make sure you make a backup of the page BEFORE you start doing this.... In case you make a mistake and the page gets "broken"...

    Have a Great Day!



    Originally Posted by ECoughlin View Post

    Hi,

    I've built my site using a Dreamweaver CS4 template and I'm trying to add Google Analytics code to it but it won't let me do it. It's been awhile since I've worked on this site so I'm a little rusty on how to do it.

    You have to add the code immediately before the /body but all that code is "gray" on my page template and when I click on it to change it, it just goes "bing". I know this is probably something simple I'm doing wrong. Anyone got any ideas?

    Thanks for your help!
    {{ DiscussionBoard.errors[1225320].message }}
  • Profile picture of the author ECoughlin
    I'm actually just trying to modify the template, I guess? Maybe that's not allowed. I looked it up on Google Analytic site and I may be adding the wrong type of code at the wrong place. They give you 2 choices so I think I'll try the other one.

    Thanks for your help. :-)
    Signature
    Hey, my name is Eunice.
    I've been an Internet Marketer since 2005.
    If you want to, you can connect with me on Facebook and Twitter. :-)
    {{ DiscussionBoard.errors[1229477].message }}
    • Profile picture of the author olivier2371
      Just a little reminder the code has to be paste between the "<head>anywhere here paste the goolge code</head>"
      Signature

      - Do you need scripts for your website. click here
      - For your weight loss needs click here
      -Free softwares, videos and e-books click here

      {{ DiscussionBoard.errors[1229714].message }}
  • Profile picture of the author Aronya
    Originally Posted by ECoughlin View Post

    I've built my site using a Dreamweaver CS4 template
    This is the real problem. DW locks much of the code in their templates, so you have these kinds of problems. You need to save the page as a standard HTML file. To do so, you may have to follow Richard's directions, but save the file as index.htm (for example). Repeat as necessary for any additional pages in your site. Also, you'll need to remember to check any internal links to your pages to make sure they still work.

    One last note: You might want to create a new site in DW, and do this work there to avoid confusion. Then, when everything works properly, replace the files on your server with the new ones, and delete the old site under DW.
    {{ DiscussionBoard.errors[1230307].message }}
  • Profile picture of the author ECoughlin
    Turns out all I had to do was make a change to the template I had made from their template and it was successful.

    Thanks for all your help, tho! Your answers helped me to figure out the problem.
    Signature
    Hey, my name is Eunice.
    I've been an Internet Marketer since 2005.
    If you want to, you can connect with me on Facebook and Twitter. :-)
    {{ DiscussionBoard.errors[1233026].message }}

Trending Topics