MyBB Community Forums

Full Version: [release] SpiceFuse Adsense Revenue Sharing!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4
After a lot of requests, and lots of procrastination from my side, I finally decided to work on and release this plugin for adsense revenue sharing.

What it does?
That's the simple part. It lets you share 25%, 50%, 75%, or 100% of your adsense revenue by displaying your member advertisements based on a smart algorithm.

Is it tough to install and understand?
It's pretty easy to install, but to understand it completely you need to pay some attention.

The revenue sharing plugin has 4 kinds of "weight" giving ways, which boost a user's chance of earning. Any one of these can be used on per-forum basis:
  1. Repliers get more weight
    As you can guess, using this will boost chances of ads display for repliers, 3 times more than the thread starter. This is ideal for the sections where users ask for help and other users offer voluntary help.
  2. Topic starters get more weight
    Using this the topic starters get 3 times more chances of having their google ads displayed. It can be better used in sections where users are start discussions that can be helpful in getting crowd.
  3. Equal Weight
    Both the thread starter and repliers get equal chance of having their ads displayed, using this setting.
  4. Only topic starters get weight
    Simple, as it says! It's either the site admins ads (if sharing is not 100%), or the topic starters ads in this section, where this setting is enabled.


Note: The revenue sharing only occurs at the topics and no where else on the forums, not on calendar, not on index.

Installation instructions available here:
http://spicefuse.com/spicefuse-adsense-r...-t-86.html

Download URL: http://spicefuse.com/mybb_mods/revenue_b2.zip
Live demo: http://spicefuse.com/index.php
Current version: 1.0 Beta 2
Last Update: May 22, 2007
Thank you...you just saved me a couple days of coding this out. It was on my todo list. Glad to see you sharing it.

Again...thank you sir.

One question though...do ads display to members from their own account? I want to ensure a person can't commit click fraud on their own ads as Google bans you for that.

EDIT: I also notice that you change the HELPDOC...does it require the file be chmod 666? Also when deactivated it doesn't remove the helpdoc section.
Could someone please explain what this mod does. Thanks
Members and admin will enter their Adsense ID. Then when the thread displays it calculates which ads to display by percentage. So members will get a certain amount of ad display on the site and possibly some revenue..hence the name "revenue sharing". It's popular of webmaster forums since most webmasters have an adsense account. I make at least $10 a month from webmaster sites I participate at that do revenue sharing.
So its an incentive for you too click on the Google adverts
tmhai Wrote:I think this is a great addition to the MyBB community! Well done Asad!
labrocca Wrote:Thank you...you just saved me a couple days of coding this out. It was on my todo list. Glad to see you sharing it.

Again...thank you sir.
Thanks for the appreciation Smile

tmhai Wrote:Just some feedback (if your willing to listen). Would it be possible to not show the ads which a specified users id is assigned to while they are viewing the threads with the ads (so, if a user clicks it, they arnt going against the google adsense terms)?
labrocca Wrote:One question though...do ads display to members from their own account? I want to ensure a person can't commit click fraud on their own ads as Google bans you for that.
This is the query that fetches the member adsense ids:
PHP Code:
        $query $db->query("SELECT {$mybb->settings[rev_fid]} as adsense_id, p.replyto, p.pid, p.fid, u.postnum, u.uid FROM ".TABLE_PREFIX."posts p LEFT JOIN ".TABLE_PREFIX."userfields c ON(c.ufid=p.uid)
                            LEFT JOIN "
.TABLE_PREFIX."users u ON(u.uid=p.uid) WHERE p.tid = '{$mybb->input[tid]}' AND u.uid <> {$mybb->user[uid]}"); 

So yes, it's excluding the "currently" logged in user's Adsense ID and that means user's own ads won't be shown to them.

labrocca Wrote:EDIT: I also notice that you change the HELPDOC...does it require the file be chmod 666? Also when deactivated it doesn't remove the helpdoc section.
It's entering the Help document directly to the mybb_helpdocs table with use_translation being set to "no". It worked well without any kind of chmod needed to language files.

I thought not to remove the help docs to save from some hassle. Some admins have this habit of deactivating the plugins before upgrading to a newer version of MyBB (and even the upgrade script recommends that).

What happens on activation is as follows:

1. A help document is inserted into database.
2. It searches for a custom profile titled like adsense ID. If found, this same custom profile field is used and saved in the settings, or else step 3 occurs.
3. The id of this help document is used to construct a "Custom Profile Field" as follows:
Adsense ID (what's this) -- here what's this is linked to that specific help document.

Now, if a user has previously deactivated the plugin and is activating it again, the third step will never be performed, and that means the link with help doc won't be updated.

I prefer not to delete the custom profile field associated with this plugin, and the help document, automatically. Instead, the forum admin can do that manually (maybe I should write that in instructions).

I wanted to release it since long, but never was getting the time to do the needful. When I got the time, it was still limited so I had to rush a bit with it. However, the original algorithm isn't rushed and has been in use at SpiceFuse forums for long enough now.

mmm hmmm.. Ideas are still welcome Smile
REally Good Edition i probally will use this one
spikescot2005 Wrote:So its an incentive for you too click on the Google adverts

NO...it's an incentive to POST...if you participate in a thread you will have a greater chance of your ad being displayed. What you are suggesting is click fraud. It's against Google TOS to give incentives to click ads. Don't even joke about it. Google has given the OK to revenue sharing forums as long as you follow the TOS.
Nice mod. Is there a way for it to work with inline ads, or adsfp plugin? so that the ad is in between each post or.. like every 5-7 posts?
Got some problem.. it wont let my users register.. keep getting some error..
Pages: 1 2 3 4
Reference URL's