Back to Modification Graveyard

Google AdSense BBCode- Let users make money by posting on your forum!
Mod Version: 1.00, by BirdOPrey5

This thread is in the Modification Graveyard.
vB Version: 4.0.x Rating: (1 vote - 5.00 average) Installs: 5
Released: 29 Jul 2010 Last Update: Never Downloads: 0
Not Supported Re-usable Code Translations External Content  

NOTICE: Some people have claimed this is against Google Terms of Service. I ran this for over 5 months without any problems from Google. I also read the Adsense TOS and Webmaster Guidelines in full and do not see where this would be against the rules. I have challenged anyone who claims it is against TOS to show me specifically where and no one has yet. I believe if you follow other Google guidelines (like limiting to no more than 3 adsense ads per page) you will be OK with Google- however I suggest you read the Adsense TOS and guidelines for yourself and make your own decision. If you do ever have a problem with google please let me know ASAP. If anyone ever tells me Google told them this was against the rules I'd have this pulled immediately. USA AT YOUR OWN RISK.

OK this BB Code is a bit more complicated then normal because it requires users who will use it to sign up for their own Google AdSense account before hand to use it.

I have read Google's TOS and believe this is allowed, it is not specifically prohibited and as long as you abide by the overall Terms of Service (no porn, no warez, no drug sites) I think this will be OK. Please read the AdSense Terms of Service for yourself of course.

I strongly suggest you limit, by way of an official announcement or such, to use only in signatures, but that is totally up to you. I also make the following suggestions:
  • You use a mod like: Advanced BBCode Permissions to limit use to only special users. (works in VB4)
  • You use a mod like: Signature only on first post (VB4) to limit 1 sig per user per page. (Google limits total ads on a page.)
  • You make sure there are only 10 posts per page so you don't overload a single page with too many ads.
  • You do your best to make sure visitors are not using ad-block software.

LIVE DEMO: http://www.juot.net/forums/showthread.php?p=838052#post838052

Add a new BBCode

Title: Google AdSense
BB Code Tag Name: ad
Replacement:
Code:
<script type="text/javascript"><!--
google_ad_client = "pub-{param}";
google_ad_slot = "{option}";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
Example: [ad="7295241582"]6709590269128756[/ad] (note: I suggest you use your own adsense code for your example)
Description: This code embeds an AdSense ad in the forum (preferably a signature).
Use Option: Yes
Button Image: (optional)
Remove Tag If Empty: Yes
All Disable Options: Yes

This was tested with 3.8.6 and 4.0.4 but should work on all current versions.

This was setup for the "Leaderboard" wide banner, if you prefer to use a different size ad make one in your google adsense and use your own code for the code replacement. Just replace the "ad client" numbers with {param} and the "ad slot" numbers with {option}.

Please mark as installed if you use this.

I suggest you give the following instructions to your users, customize as needed:

Ad Sense is a popular advertising service by Google. You can sign up with them at https://adsense.google.com and start earning money by displaying ads. Forum owners usually already have a Google Adsense account. What this bb code does is allow any forum poster to be able to bring in some extra money by advertising a google ad in their signature. This particular bb code is set for the standard Google banner size of 728x90 pixels which will fit nicely in most signatures. It can of course be adapted to any ad size the administrator chooses by changing the hard coded size in the replacement text.

To make use of this code:
1. Sign up for a google adsense account https://adsense.google.com
  • Answer all questions honestly.
  • Use this website address as your website URL.
  • It may take up to 2 or 3 days for your account to be verified.
2. While logged into "AdSense" click on the "AdSense Setup" tab.
3. Click on "AdSense for Content"
4. Select "Ad Unit (text and image ads - default)" and hit Continue.
5. Choose format "728x90 Leaderboard" and any other settings you want.
6. Choose a corner style (your choice) and hit Continue.
7. For "Choose Ad Channels" Just skip this if it doesn't apply and hit Continue.
8. Give your ad unit a name if you want, the default is fine, hit "Submit and Get Code"

You will be given a code that looks something like this:
Code:
<script type="text/javascript"><!--
google_ad_client = "pub-6709590269128756";
/* BBCode 728x90, created 7/29/10 */
google_ad_slot = "7627109992";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
There are two numbers you need to write down or copy for later use.
In this example the first one is: 6709590269128756 this is the "ad client" and will go between the "ad" bb code tags.
The second number is the "ad slot" and in this case is: 7627109992. This goes in the "option" part of the tag.
Therefore to use this ad your code would be:

[ad="7627109992"]6709590269128756[/ad]

and that would produce: (Screen Shot)


Note: It's very likely if you are trying this for the first time it will be blank for you. Google sometimes takes up to about 10 minutes after the ad was created before actually displaying an ad. Give it time, an ad WILL show eventually.

Please limit the use to 1 instance in your signature if you choose.

Google Terms of Service prevents me from giving exact numbers on how much you may make. Suffice to say it depends heavily on how many places the ad shows up and how many people see it. Overall board traffic will figure heavily on this. I'd expect you may make as little as nothing up to several dollars a day, more depending on the number of clicks you may get. If your signature is in a 'public' forum that gets indexed by google you will see the ad that shows in time will be relevant to the content of the thread, if you make a thread about "Forex Trading" and it stays on topic in time (maybe a day) the ads displayed will be primarily about "Forex Trading." If your entire forum is about one topic you will likely get ads related to that.

Download

No files for download.


vblts.ru supports vBulletin®, 2022-2024