Using php include with google ads?

Discussion in 'Guidelines / Compliance' started by billabong7329, Feb 26, 2007.

  1. #1
    I want to have a php file with all my header and side bars and I was wondering if I could stick the adsense code in that and use an include method to have it on every page. Is this against the TOS? If it isn't, will it even work correctly?
     
    billabong7329, Feb 26, 2007 IP
  2. frankcow

    frankcow Well-Known Member

    Messages:
    4,859
    Likes Received:
    265
    Best Answers:
    0
    Trophy Points:
    180
    #2
    That will work just fine. PHP includes are processed on the server, and therefore this is transparent to any visitor, Google included
     
    frankcow, Feb 26, 2007 IP
  3. billabong7329

    billabong7329 Peon

    Messages:
    280
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #3
    And it will still generate ads relevant to the context on that page, correct? And this isn't breaking the TOS in anyway?
     
    billabong7329, Feb 26, 2007 IP
  4. kemus

    kemus Guest

    Messages:
    487
    Likes Received:
    19
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Yes and no

    The way it works is that the PHP is processed first, adding adsense to the site, and then the Javascript which makes the ads runs, making the ads prefectly relevant.
     
    kemus, Feb 26, 2007 IP
  5. commandos

    commandos Notable Member

    Messages:
    3,648
    Likes Received:
    329
    Best Answers:
    0
    Trophy Points:
    280
    #5
    google will never know that you are using the include , they will only see a simple page .

    and the ads will depend on what there is on the page ..
     
    commandos, Feb 26, 2007 IP
  6. chaos0784

    chaos0784 Peon

    Messages:
    33
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Why would it break their TOS? It is perfectly valid, and they will never know the difference. When the Googlebot comes around all it will see is the HTML. It cannot look at your PHP because that is server side. As for it affecting your ads: their scripts run completely separately of your server, so you can do virtually whatever you want and not change those. As long as the ads are there, and can be recognized easily by the end user for what they are (IE: not being deceitful about it), then you are good. I'll give it a quick double check for you, but I am 99% positive on this one.
     
    chaos0784, Feb 26, 2007 IP
  7. commandos

    commandos Notable Member

    Messages:
    3,648
    Likes Received:
    329
    Best Answers:
    0
    Trophy Points:
    280
    #7

    make it 100% :)
     
    commandos, Feb 26, 2007 IP
  8. chaos0784

    chaos0784 Peon

    Messages:
    33
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #8
    Then later it has a small deal about using scripts to automatically click links for you, but as long as the script doesn't click the links or break the above rules you are good to go.

    Exactly. I just wanted to prove my point within their TOS.
     
    chaos0784, Feb 26, 2007 IP
  9. frisby

    frisby Well-Known Member

    Messages:
    1,378
    Likes Received:
    39
    Best Answers:
    0
    Trophy Points:
    140
    #9
    PHP is server side, so noone on the other side can find out, what is going on at your server.
     
    frisby, Feb 26, 2007 IP
  10. frankcow

    frankcow Well-Known Member

    Messages:
    4,859
    Likes Received:
    265
    Best Answers:
    0
    Trophy Points:
    180
    #10
    I am 101% positive on this. It's impossible to tell if you're using PHP includes
     
    frankcow, Feb 26, 2007 IP
  11. login

    login Notable Member

    Messages:
    8,849
    Likes Received:
    349
    Best Answers:
    0
    Trophy Points:
    280
    #11
    100% yes , I and thousands others are doing this, saves me a lot of work.
     
    login, Feb 26, 2007 IP
  12. commandos

    commandos Notable Member

    Messages:
    3,648
    Likes Received:
    329
    Best Answers:
    0
    Trophy Points:
    280
    #12
    Except if php errors start to occur :p :D
     
    commandos, Feb 26, 2007 IP
  13. billabong7329

    billabong7329 Peon

    Messages:
    280
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #13
    oh SWEET. This will save so much hassle and it will make changing colors on layouts so much easier.

    Thanks a lot.
     
    billabong7329, Feb 26, 2007 IP
  14. Erind

    Erind Peon

    Messages:
    663
    Likes Received:
    15
    Best Answers:
    0
    Trophy Points:
    0
    #14
    Everyone is doing it.. well not everyone, but everyone who wants to make the ads mobile and time-saving when editing.
     
    Erind, Feb 26, 2007 IP
  15. master_06

    master_06 Peon

    Messages:
    289
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #15
    Generating content relevant ads based on the context of any page using PHP is i think allowable in the TOS as long as you don't use PHP in tweaking your ads aside from the allowed use of colors and texts in the user CP.:D
     
    master_06, Feb 28, 2007 IP
  16. chris20492002

    chris20492002 Guest

    Messages:
    1,136
    Likes Received:
    23
    Best Answers:
    0
    Trophy Points:
    0
    #16
    you can do whatever around the code you just cannot alter the code itself.
     
    chris20492002, Mar 5, 2007 IP