adding GA in phpld template?

Discussion in 'Directories' started by templates, Oct 26, 2011.

  1. #1
    i am unsure on which file to add my GA code in phpld 4 stock template..can someone point this out?
     
    templates, Oct 26, 2011 IP
  2. conspicuous

    conspicuous Peon

    Messages:
    36
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Try adding your analytics code to header.tpl - right before the </head> tag.
     
    conspicuous, Oct 26, 2011 IP
  3. dvduval

    dvduval Notable Member

    Messages:
    3,372
    Likes Received:
    356
    Best Answers:
    1
    Trophy Points:
    260
    #3
    And if you want to add google adsense to one of the widget zones, it is already built in. Just go to
    Admin > Widgets > Available Widgets
    And turn on something like Adsense Central widget.
     
    dvduval, Oct 26, 2011 IP
  4. karthimx

    karthimx Prominent Member

    Messages:
    4,959
    Likes Received:
    127
    Best Answers:
    2
    Trophy Points:
    340
    #4
    Open your templates folder and add the GA code in header.tpl file before </head>

    yoururl/templates/header.tpl
     
    karthimx, Oct 26, 2011 IP
  5. dvduval

    dvduval Notable Member

    Messages:
    3,372
    Likes Received:
    356
    Best Answers:
    1
    Trophy Points:
    260
    #5
    Sorry, I wasn't sure if you meant Google Adsense or Analytics. :) For analytics in phpLD 4.1 just go to
    Admin > Settings > Site
    And there is place to paste the analytics code. Also, interestingly you can paste your Piwik code there too. I actually prefer Piwik to Analytics.
     
    dvduval, Oct 27, 2011 IP
  6. an0n

    an0n Prominent Member

    Messages:
    5,688
    Likes Received:
    915
    Best Answers:
    0
    Trophy Points:
    360
    #6

    [​IMG]
     
    an0n, Oct 27, 2011 IP
  7. citi

    citi Active Member

    Messages:
    143
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    68
    #7
    Basically the GA is a small script of code which needs to be added just before the </head> tag so that the page does not take the extra time to load. It is to be put on every page that you want to track or if you are using a common page for the whole site then it should be included in that page like header.xxx or foooter.xxx.
     
    citi, Dec 8, 2011 IP