vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Adsense Revenue Sharing Hack 1.1 (0 queries version) (https://vborg.vbsupport.ru/showthread.php?t=80685)

AlexanderT 04-27-2005 10:00 PM

Adsense Revenue Sharing Hack 1.1 (0 queries version)
 
Upgrade 1.1 notice:
The upgrade from 1.0 to 1.1 is optional; it makes sure ads don't display in private messages. Thanks to venomx for the tip.

Hack Description:
This hack will allow you to offer Google Adsense revenue sharing to your vBulletin board users. Revenue sharing is a great way to reward your board members for their loyalty and adds a feeling of ownership in the board and it's success. Revenue is split between board administrator and thread starters. The percentage of probability is customizable by the administrator.

This hack is fundamentally the same like this hack; however, it adds some customization plus does not use any additional queries!

I wrote this hack a couple of months ago and didn't know there was any interest for it (you certainly don't want to spend money on something that doesn't take much time to code).

My time is *very* limited so I am not good at giving support. I hope the instruction included is self-explanatory. It is easy to expand the hack to your needs.

ChrisSy 04-28-2005 10:07 AM

This sounds like a really great idea, im just a little hesitant that thread starters may get a bit 'click happy' on the ads, google doesnt like that kind of thing.

AlexanderT 04-28-2005 10:28 AM

Chris, you can enter a "Minimum Posts" count before ads are contributed to users. This way you can make sure only long-time board visitors participate in the system.

Polo 04-28-2005 12:46 PM

Wow, I missed this post before... looks like a great hack... howerver I'm still waiting to see an official answer from google in wheter this hack not breaking the TOS

AlexanderT 04-28-2005 12:55 PM

Polo, did you miss my answer in the other thread? I asked Google and here is their response in full:
Quote:

Hello Alexander,

Thanks for your email.

To clarify, please note that you may continue displaying ads from
different publishers on your site. However, we ask that you not place ads
from two different accounts on the same web page. We appreciate your
cooperation.

Please feel free to reply to this email if you have additional questions
or concerns.
Sincerely,

James
The Google AdSense Team

Polo 04-28-2005 01:00 PM

oh I think i missed it, thank you for that post ;) glad that google accepts this... thank you very much for the hack...

T3MEDIA 04-28-2005 01:28 PM

Can you tell me how does it work. I see what it does but I would like to know how does it work....

Thanks.

Polo 04-28-2005 01:32 PM

https://vborg.vbsupport.ru/showpost....8&postcount=25 :)

LEAD_WEIGHT 05-01-2005 06:25 AM

It does not display at my forum even with the edits i made, so whats up with that
http://www.theundergroundsource.com/forums/index.php?
User Name :
Password :

I uninstalled it for now until I can figure it out!

AlexanderT 05-01-2005 08:05 AM

If you actually read what I said in my first post you would know that I don't have much time; that doesn't mean I am not willing to help when I can. Of course the hack does not display at your forumhome, http://www.theundergroundsource.com/forums/index.php?, because it is not supposed to. It displays ads in the thread view, e.g.

http://www.mobileread.com/forums/sho...?threadid=3968

Anyways.... if there is nothing but complaint, I have no trouble removing it again.

LEAD_WEIGHT 05-01-2005 08:08 AM

Quote:

Originally Posted by AlexanderT
If you actually read what I said in my first post you would know that I don't have much time; that doesn't mean I am not willing to help when I can. Of course the hack does not display at your forumhome, http://www.theundergroundsource.com/forums/index.php?, because it is not supposed to. It displays ads in the thread view, e.g.

http://www.mobileread.com/forums/sho...?threadid=3968

Anyways.... if there is nothing but complaint, I have no trouble removing it again.

I know it does not display that way it just does not display in threads or any posts I have made or did a test on.

I found what was wrong it was cause I am in user group 6 Admin. How do u make everyone show up to see the ads.

Thanks for the info
Quote:

Originally Posted by AlexanderT
When you change the postbit templates, instead of:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

add this:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID'])">

when applying the code changes in 7. of the instruction.


AlexanderT 05-01-2005 10:06 AM

When you change the postbit templates, instead of:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

add this:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID'])">

when applying the code changes in 7. of the instruction.

Polo 05-01-2005 09:34 PM

you can always use conditionals ;)

LEAD_WEIGHT 05-01-2005 11:18 PM

Quote:

Originally Posted by Polo
you can always use conditionals ;)

explain more?



Quote:

Originally Posted by CallieJo2
What if we only want this for moderators and not all registered members?
Possible?
Thanks ;-)

Change the UserGroup ID # to 7 instead of # 2 in your postbit & postbit_legacy templates
when applying the code changes in step 7. of the instruction..

Code:

<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

LEAD_WEIGHT 05-01-2005 11:31 PM

I was looking at the code & I notice that u can place your own type of ads and make them scroll or rotate. I going to test this out to see if I can do that and change some wording in Admin c/panel display in vb. :ermm:

T3MEDIA 05-02-2005 02:42 PM

Ahh thank you.... This in fact then is not a a revenue sharing hack what so ever then....

That is what I wanted to know. Thanks.

Quote:

Originally Posted by Polo


Polo 05-02-2005 02:49 PM

Quote:

This in fact then is not a a revenue sharing hack what so ever then....
What? Didnt understand a word you just said...

T3MEDIA 05-02-2005 02:50 PM

Quote:

Originally Posted by Polo
What? Didnt understand a word you just said...

I typed a twice. Thanks... its ok

Polo 05-02-2005 02:51 PM

Quote:

Originally Posted by T3MEDIA
I typed a twice. Thanks... its ok

again... what??? you typed what twice? :confused:

T3MEDIA 05-02-2005 03:04 PM

Quote:

Originally Posted by Polo
again... what??? you typed what twice? :confused:

I typed if you look at the post the letter "A" twice which in turn threw you off completely to what I was saying.
the second post I said "I typed a twice. Thanks... its ok" I assumed you saw what I was talking about.

If you still have problems you can contact me via PM. I dont want this thread to go off topic.

Milez 05-03-2005 01:19 AM

I installed this and modified it so that the revenue sharing only was available for mods/admins. Works great so far!

LEAD_WEIGHT 05-03-2005 04:43 AM

Quote:

Originally Posted by Milez
I installed this and modified it so that the revenue sharing only was available for mods/admins. Works great so far!

U made it so it shares revenue how u do that, unless u share your pub=# in other forums. I am right on this or just a guess. :ermm:

AlexanderT 05-03-2005 07:26 AM

Quote:

Originally Posted by LEAD_WEIGHT
U made it so it shares revenue how u do that...

But this is the whole point of the hack.... sigh.

xtreme-mobile 05-03-2005 07:59 AM

so sorry to be dull guys but if i install this

it will display ads through out threads etc and then every time a member clicks a ad i get some cash for it????

cheers

LEAD_WEIGHT 05-03-2005 10:22 AM

Quote:

Originally Posted by AlexanderT
But this is the whole point of the hack.... sigh.

Sorry is just others are saying it does not share revenue within own forum.
I figure it was by sharing by forums who have this hack. I thought it could of been like u get some of the other persons revenue if they post it in your forum, but I know that could not be that easy to get money from other ppl's ad. I knew u could only earn what is your own ads .
That is what I was trying to figure out what they were saying.
So what is the big diff. between yours & the more $$$ one. I know that it has other features but what else. I want to know just incase someone decides to add something else to it. reverse engineering :pirate:

Quote:

Originally Posted by xtreme-mobile
so sorry to be dull guys but if i install this

it will display ads through out threads etc and then every time a member clicks a ad i get some cash for it????

cheers

I belieave the under the first post on every page . That is what I see it as. & yes u get paided for every click that someone else does not yourself unless u want them to banned u and it is base on the amount of members if u have some of your friends clicking on it. They can banned u for that as well & just banned u for no reason as well. :ermm:

T3MEDIA 05-03-2005 12:34 PM

Not to start drama but this isnt revenu sharing it rotates adsense #'s

To be revenu sharing it would mean you USE my # and we split the costs...
almost like a adsense affliate. That would be hot. That is what I thought it was.

Milez 05-03-2005 03:03 PM

Wow is it just me or is everyone missing the boat on this one?

Anyways Nice one AlexanderT. Been looking at coding this myself for some time but you did a much better job than I would have.

AlexanderT 05-03-2005 11:49 PM

Quote:

Originally Posted by T3MEDIA
Not to start drama but this isnt revenu sharing it rotates adsense #'s

Uhm and what does rotating adsense client ids effectively do? It enables users to share revenue generated from Adsense clicks on your board. Hence Adsense Revnue Hack.

Quote:

Originally Posted by T3MEDIA
That would be hot.

...and that would violate Google's terms.

LEAD_WEIGHT 05-03-2005 11:58 PM

Quote:

Originally Posted by T3MEDIA
Not to start drama but this isnt revenu sharing it rotates adsense #'s

To be revenu sharing it would mean you USE my # and we split the costs...
almost like a adsense affliate. That would be hot. That is what I thought it was.

Nah, it is great the way it is. If u want to get yourself banned then I got some great ways for u for getting banned quickly at my unfinished forum.
http://www.theundergroundsource.com/...splay.php?f=24

Odd #66.XXX.66.XXX :laugh:

beano33 05-04-2005 04:59 PM

Quote:

Originally Posted by CallieJo2
What if we only want this for moderators and not all registered members?
Possible?
Thanks ;-)

You can use conditionals in the modifyoptions template so the new profile fields added are only visable for the usergroups you want.

See #2 in this thread

beano33 05-05-2005 09:47 PM

Before I installed this hack I had my ad code in the showthread template where they were displayed after the last post. I modified that code for google_ad_client = "$post[ad_client_id]";
google_ad_channel ="$post[ad_channel]";
but it wasn't inserting any client id so no one way getting paid. :(

So I removed the ad code from showthread and put it in the postbit template as suggested in the hack instructions. It works fine as far as functionality is concerned, but now the ads appear after the first post and we'd prefer them to show after the last post.

Can anyone tell me how to do one of the following:

1) make the hack work with the ad code in the showthread template, OR
2) get the ad code in the postbit legacy template to display after the last post instead of the first post.

Thanks!

P.S. I changed it back to putting the ads after the last post so you can see where we'd like it. Here is the forum: http://hfboards.com/

venomx 05-07-2005 06:50 AM

Yeah what beano33 asked and is there a way to also have it pick a random member that has posted a reply?

Like:
Admin 50%
Thread starter: 25%
Random member who has replied: 25%

Or even:

Admin 50%
Thread starter: 25%
Last member to reply: 25%

venomx 05-07-2005 01:25 PM

hmm this makes adsense show on PMs too... does google allow that?

AlexanderT 05-07-2005 03:55 PM

Quote:

Originally Posted by venomx
hmm this makes adsense show on PMs too... does google allow that?

How should this make asense show on PMs if only postbit templates and showthread.php is modified?

venomx 05-07-2005 04:11 PM

Thats the only onnes I modified... I put the postbit part right in the bottom of the edit window, could that be it?

I edited the showthread.php as you said then opened postbit leg.. and dropped it right into the very bottom of it. Then when I got a PM it was right under the PM... I fixed it by adding a THIS_SCRIPT='SHOWTHREAD' to the postbit and it stopped showing...

venomx 05-07-2005 04:50 PM

So noone else has had this happen?

AlexanderT 05-07-2005 06:04 PM

Quote:

Originally Posted by venomx
So noone else has had this happen?

I see now. Thanks for the hint. The PM routines happen to use the same postbit templates that are also used by showthread (it never occured to me to check PM out). Your suggestion for an additional IF conditional is correct if you don't want to have ads shown in private messages.

I uploaded version 1.1 of this hack where ads are explicitely shown only in showthread instances. Upgrade instruction is included:

Quote:

If you plan on upgrading from 1.0 to 1.1 of this hack, you only need to edit your postbit templates.

In both postbit and postbit_legacy, find:

<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

and replace it with:

<if condition="THIS_SCRIPT == 'showthread' AND ($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

Done.

venomx 05-07-2005 06:07 PM

So any suggestions on making it post below the posts in the showthread.php?
Though the placement after the first post is growing on me,,, lol

Anyone edit this to share with ALL posters in a thread and not just the starter?

One last question.. :)
Can we make it also post right under the last post in the thread? Was just thinking I could put a conditional around the one after the first ost to show to only non membes and have the other show after the last post on the page to all with a conditional that would only add it if there was 3 posts after the first post...

venomx 05-07-2005 06:12 PM

More thinking.. This would rock :)

Unregistered visitor
Post #1
Ad
Post #2
Post #3
Post #4
Post #5
Ad

Registered with 5 posts
Post #1
Post #2
Post #3
Post #4
Post #5
Ad

Unregistered and Registered with say 3 posts

Post #1
Ad
Post #2
Post #3

LEAD_WEIGHT 05-10-2005 12:06 AM

Quote:

Originally Posted by CallieJo2
Thanks for the tips to help me get started ;) I appreciate it bunches!
And thanks bunches for this cool hack! ;)

Have a splendid evening ;)

Another easy way or u can let everyone see it that is what I did to my site.
Code:

https://vborg.vbsupport.ru/showpost.php?p=648365&postcount=15

Code:

Originally Posted by AlexanderT
When you change the postbit templates,
Find this:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID']) AND (!$show['member'] OR $bbuserinfo[usergroupid] == 2)">

Replace with this:
<if condition="($post['postid'] == $GLOBALS['FIRSTPOSTID'])">

when applying the code changes in 7. of the instruction.



All times are GMT. The time now is 11:50 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01611 seconds
  • Memory Usage 1,844KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (22)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete