News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Ad Management mod

Started by SMFHacks.com Team, January 30, 2006, 08:41:19 PM

Previous topic - Next topic

Tanfies2

I've been using this Mod for years now, and it's been brilliant, allowing me to place Google Ads in specific places around my Forum.

However, Google are getting really picky lately on where you can and can't place their Ads, especially in places where there is low content, and class it as a violation.

Due to this, I've now got to make sure that Ads don't appear on low content pages, such as my members area, or when users view other members profiles etc.


https://www.friendsoffulham.com/forum/index.php?action=mlist


At the moment, I just ask the Mod to display an Ad on every page right below the menu, but as you can imagine, this shows up on every page, including pages with low content.

The URL's that Goggle are flagging up are these, and are wondering if the Mod can exclude anything that maybe has 'action' in it?

1. https://www.friendsoffulham.com/forum/index.php?action=unread
2. https://www.friendsoffulham.com/forum/index.php?action=unreadreplies
3. https://www.friendsoffulham.com/forum/index.php?action=profile;u=361443

Any help, advice would be appreciated, looks like I'm running on version 3.5d


vbgamer45

Requires a manual code edit.
You can edit Sources/LoadAds.php

Find
// 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' || $_REQUEST['action'] == 'login' || $_REQUEST['action'] == 'login2' || $_REQUEST['action'] == 'register' || $_REQUEST['action'] == 'register2' || $_REQUEST['action'] == 'reminder'))
return ;


And then add other actions to the list.
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Tanfies2

Quote from: vbgamer45 on April 11, 2024, 03:58:13 PMRequires a manual code edit.
You can edit Sources/LoadAds.php

Find
// 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' || $_REQUEST['action'] == 'login' || $_REQUEST['action'] == 'login2' || $_REQUEST['action'] == 'register' || $_REQUEST['action'] == 'register2' || $_REQUEST['action'] == 'reminder'))
return ;


And then add other actions to the list.
Quote from: vbgamer45 on April 11, 2024, 03:58:13 PMRequires a manual code edit.
You can edit Sources/LoadAds.php

Find
// 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' || $_REQUEST['action'] == 'login' || $_REQUEST['action'] == 'login2' || $_REQUEST['action'] == 'register' || $_REQUEST['action'] == 'register2' || $_REQUEST['action'] == 'reminder'))
return ;


And then add other actions to the list.

Thanks for getting back to me.

I'm absolutely pants at doing stuff like that, and wouldn't even know where to start :-( 

vbgamer45

Just add another entry like for member list add to it
$_REQUEST['action'] == 'admod' || $_REQUEST['action'] == 'mlist' ||
Community Suite for SMF - Take your forum to the next level built for SMF, Gallery,Store,Classifieds,Downloads,more!

SMFHacks.com -  Paid Modifications for SMF

Mods:
EzPortal - Portal System for SMF
SMF Gallery Pro
SMF Store SMF Classifieds Ad Seller Pro

Advertisement: