Pligg CMS Forums


Go Back   Pligg CMS Forum > Pligg Development > Modification Tutorials



EASY NO WORRIES PAINLESS adsense revenue sharing mod placement mod guide

Advanced Tutorials for Modifying your Pligg site


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-17-2007, 03:27 AM
New Pligger
 
Join Date: Apr 2007
Posts: 7
EASY NO WORRIES PAINLESS adsense revenue sharing mod placement mod guide

first of all thanks to dravis of plugim for the adsense mod. And thanks to ashdig and gang for implementing it.


I like to draw your attention to what I've discover. Which is a very easy way to place the adsense ads using the adsense revenue sharing module



you will need to
1.modify the modules\share_revenue\share_revenue_init.php file
2.add show_ads files into the modules\share_revenue\templates directory
3.modify the templates files IE \templates\yget\sidebar




After activating the adsense revenue sharing mod using the module admin panel.

STEP 1 modify the appearance pages
modify lines 7 and 8 to set the pages you want the ads to appear in

7 $include_in_pages = array('all');
8 $do_not_include_in_pages = array();


STEP 2 modify the ad locations setting and add new ad locations setting
goto line 14.

14 module_add_action_tpl('tpl_pligg_below_center', share_revenue_tpl_path . 'show_ads.tpl');



since adsense display only 3 ads bar per page. So Let's say you want the ads to appear in sidebar below, top center as well as bellow center.

since line 14 already covers below_center. just add sidebar and top. like bellow

14 module_add_action_tpl('tpl_pligg_below_center', share_revenue_tpl_path . 'show_ads.tpl');
15 module_add_action_tpl('tpl_pligg_top_center', share_revenue_tpl_path . 'show_ads_top_center.tpl');
16 module_add_action_tpl('tpl_sidebar_below_center', share_revenue_tpl_path . 'show_ads_sidebar_below.tpl');

by default show_ads.tpl only shows 2 ads units and the wording is grey in color. You can use show_ads.tpl if you want to use the same setting for all 3 ad locations. In this guide we will be changing the settings of each ad location.
if so your line 14,15,16 will look like this


14 module_add_action_tpl('tpl_pligg_below_center', share_revenue_tpl_path . 'show_ads.tpl');
15 module_add_action_tpl('tpl_pligg_top_center', share_revenue_tpl_path . 'show_ads.tpl');
16 module_add_action_tpl('tpl_sidebar_below_center', share_revenue_tpl_path . 'show_ads.tpl');

ignore step 3 if you are using the same ads settings for all the locations



IMPORTANT - make sure you set your publisher-id in show_ads.tpl as well as the relevant ad settings


Step 3
create the files show_ads_top_center.tpl, show_ads_sidebar_below.tpl in the modules\share_revenue\templates directory
each with the ads setting you want. Use show_ads.tpl as your template and change where it is relevant.


Step 4.
Modify the templates files to show your ads. This is the easy painless and most important of all CLEAN part.

open the templates files. in this guide it would be templates\yget\sidebar.tpl to the bottom of the page

21 {checkActionsTpl location="tpl_sidebar_below_center"}


tpl_pligg_above_center and tpl_pligg_below_center has already set in pligg.tpl.

104 {checkActionsTpl location="tpl_pligg_above_center"}
105 {include file=$tpl_center.".tpl"}
106 {checkActionsTpl location="tpl_pligg_below_center"}





This guide helps you edit the templates leaving behind a very clean source for future edits. you can easily edit the templates to place your ads in a way that does not
make the templates look like a spaggheti.

Hope you like it. May be you guys can include it the \modules\share_revenue\share_revenue_readme.htm .
so that admins can see it after they have install it. if you need my services in installing your pligg site. Please contact me via the forum.


cheers,
johntheentrepreneur
johnthebillionaire.blogspot.com / thelosthub.com

Vist me at TheLostHub.com - Daily LOST tv news

Blobees.com - Share your positivity - Law of Attraction

Last edited by johntheentrepreneur; 04-17-2007 at 03:31 AM.
Reply With Quote
Sponsor
  #2 (permalink)  
Old 07-26-2007, 12:31 PM
New Pligger
 
Join Date: Jul 2007
Posts: 8
there is a problem though some times side bar and the main body show different ads
Reply With Quote
  #3 (permalink)  
Old 07-26-2007, 12:39 PM
New Pligger
 
Join Date: Jul 2007
Posts: 8
there is a problem though some times side bar and the main body show different ads
Reply With Quote
  #4 (permalink)  
Old 03-11-2008, 01:47 PM
New Pligger
 
Join Date: Feb 2008
Posts: 25
Hi thank you for this uselfull tutorial.

But for this to work you should change in pligg.tpl this:
{checkActionsTpl location="tpl_pligg_above_center"}

By this

{checkActionsTpl location="tpl_pligg_top_center"}

Last edited by yagami; 03-11-2008 at 02:18 PM.
Reply With Quote
  #5 (permalink)  
Old 12-06-2008, 05:56 PM
Constant Pligger
 
Join Date: May 2007
Posts: 160
Quote:
Originally Posted by yagami View Post
Hi thank you for this uselfull tutorial.

But for this to work you should change in pligg.tpl this:
{checkActionsTpl location="tpl_pligg_above_center"}

By this

{checkActionsTpl location="tpl_pligg_top_center"}

does anyone khow where can I change the % of the adsense sharing?
Reply With Quote
  #6 (permalink)  
Old 12-06-2008, 06:07 PM
chuckroast's Avatar
Coder/Designer
Pligg Version: 1.0
Pligg Template: Shredit
 
Join Date: Jun 2006
Location: PA
Posts: 3,390
Quote:
Originally Posted by onlinebisnes View Post
does anyone khow where can I change the % of the adsense sharing?
Go to admin> user management and select a user. Click edit. Now along with editing information, you can set the adsense share percentage. Each user can be set to different values.


Thank this developer

Get the Pligg 1.0 Module Pack and more ---> download here




Reply With Quote
  #7 (permalink)  
Old 12-07-2008, 02:05 AM
Constant Pligger
 
Join Date: May 2007
Posts: 160
Thanks,
but is it possible to have one edit that automatically set % for all user?
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Adsense Revenue Sharing Mod for 8.2 Dravis Modification Tutorials 39 03-02-2009 01:16 PM
Adsense revenue sharing and ad placement yagami General Help 0 03-10-2008 10:24 AM
Adsense Placement In Revenue Sharing Module spuds General Help 0 01-14-2008 01:49 PM
Google adsense revenue sharing, question dadaas Modification Tutorials 0 10-03-2007 01:13 PM
Adsense Revenue Sharing Placement Question??? onouchs General Help 8 03-26-2007 06:14 PM

Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Use the coupon code PLIGG at Dreamhost.com to receive a discount of up to $84.00 Make a donation to support Pligg CMS development