Coinbase

Author Topic: Quite Important Adsense Feature for TOS  (Read 4653 times)

0 Members and 1 Guest are viewing this topic.

Offline daisukey

  • Newbie
  • *
  • Posts: 2
Quite Important Adsense Feature for TOS
« on: July 06, 2007, 09:23:46 pm »
http://www.simplemachines.org/community/index.php?topic=180988.msg1152454#msg1152454

Quote
Okay, is there a mod which allows us to avoid ads to be shown in certain pages like register.php private.php? I believe showing google ads on these pages is against their TOS.

Or is there an alternative way to avoid this by simply modifying the template? I'm not a coder so any help is appreciated.

cheers.

Offline bigguy

  • Support
  • Elite Member
  • *
  • Posts: 1518
    • SMF Helper
Re: Quite Important Adsense Feature for TOS
« Reply #1 on: July 06, 2007, 10:17:31 pm »
Answered on simple machines and quoted here:

Quote
If you are worried about it and you are using the ad mod then just don't post google ads at the top, bottom, under the menu or in the welcome user area of the forum. There are still loads of other places to put your google ads. :)

Offline daisukey

  • Newbie
  • *
  • Posts: 2
Re: Quite Important Adsense Feature for TOS
« Reply #2 on: July 06, 2007, 10:23:21 pm »
hey thanks.

but is it possible not to display the ads in certain pages by using a conditional statement? like
Quote
if this is register.php page then do NOT display the following code.

Just an idea to make this mod better.  :)

Offline bigguy

  • Support
  • Elite Member
  • *
  • Posts: 1518
    • SMF Helper
Re: Quite Important Adsense Feature for TOS
« Reply #3 on: July 06, 2007, 10:53:54 pm »
I think it is possible and I will submit this thread to Jerm and see what he can come up with. :)

Offline jerm

  • Support
  • Elite Member
  • *
  • Posts: 726
Re: Quite Important Adsense Feature for TOS
« Reply #4 on: July 08, 2007, 08:17:18 pm »
Ya, its pretty easy actually. Do you know any basic coding?

Look into LoadAds.php in your sources directory(assuming you have already installed the mod)

Code: [Select]
//For security reasons, we don't want to display ads if the action is "admin" or "admod"
if(isset($_REQUEST['action']) && ($_REQUEST['action'] == 'admod' || $_REQUEST['action'] == 'admin'))
return ;

As you can see, ads can't be displayed if the action=admod . You can follow the same idea for any other action there is. Good?

Offline Cookiemonster

  • Newbie
  • *
  • Posts: 1
    • ZTZ site
Re: Quite Important Adsense Feature for TOS
« Reply #5 on: July 15, 2007, 02:15:12 pm »
yeah, but you can still see them on the registration page with me:
http://ztz.110mb.com/smf/index.php?action=join

Offline jerm

  • Support
  • Elite Member
  • *
  • Posts: 726
Re: Quite Important Adsense Feature for TOS
« Reply #6 on: August 25, 2007, 10:22:06 am »
Adll you need to do is add this to the end
|| $_REQUEST['action'] == 'register'

SMF Ads Support Forum

Re: Quite Important Adsense Feature for TOS
« Reply #6 on: August 25, 2007, 10:22:06 am »
.