The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
vBulletin Google Adsense Deep Integration Tutorial
This tutorial is written to show you how to use your Google Adsense codes efficiently in your vBulletin (3.5+) templates. I have a very heavily modified vBulletin style but i used the original style for this tutorial to be simple and match the colors. You can change everything as you want to find the most fitting results for your vBulletin. Alternate ads-PSAs to Collapsible ads: Quote:
Create a HTML file with this code and save it as collapsible_ad.html: HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title></title> <script src="http://pagead2.googlesyndication.com/pagead/google_adsense_script.js" type="text/javascript"></script> </head> <body style="background-color: transparent;"> </body> </html> Go to your Google Adsense account and grap your google_ad_client and google_ad_channel codes. (google_ad_channel is optional) Open Notepad and paste these codes as you will change them with youradsensecode and yourchannelcode on the following steps. We will use these there ad layouts in this tutorial: 728 x 90 Leaderboard 468 x 60 Banner 234 x 60 Half Banner ...and one link unit: 468 x 15 Note: navbar template editing step is optional because it may be against the Google Adsense rules for you. If you edit navbar template, almost all of your vBulletin pages will have Adsense ads at the top of the pages. My navbar and header templates include some flash, gif and text content and i update them regularly. It's why i use Adsense ads in navbar. You may apply this step (the ad unit) manually to your FORUMHOME, FORUMDISPLAY, etc templates... Open your navbar template: vBulletin AdminCP > Styles & Templates > Edit Templates > Navigation / Breadcrumb Templates > navbar (for the link unit) Find: Quote:
Quote:
(for the ad unit) Find: Quote:
Quote:
Save. Open your FORUMDISPLAY template: vBulletin AdminCP > Styles & Templates > Edit Templates > Forum Display Templates > FORUMDISPLAY (First thread) Find: Quote:
Quote:
(Last thread) Find: Quote:
Quote:
Save. https://vborg.vbsupport.ru/showthread.php?t=102466 Open your search_results template: vBulletin AdminCP > Styles & Templates > Edit Templates > Search Templates > search_results (First result) Find: Quote:
Quote:
(Last result) Find: Quote:
Quote:
Save. Open your postbit(legacy) template: vBulletin AdminCP > Styles & Templates > Edit Templates > Postbit Templates > postbit(legacy) (First post and last shown post) Find: Quote:
Quote:
https://vborg.vbsupport.ru/showpost....30&postcount=7 Results: vBulletin Google Adsense Deep Integration Tutorial by NeutralizeR @ www.MsXLabs.org |
#17
|
|||
|
|||
thanks...
|
#18
|
|||
|
|||
Hi
I seem to be having trouble with the FORUMDISPLAY integration - the code seems to be working as there is a correct layout at the top of the forum, but the google adsense banner does not show. |
#19
|
|||
|
|||
Quote:
|
#20
|
||||
|
||||
Remember however if you have multiple areas for which you are showing adsense on one page, but google doesn't have enough ads to fill all the spots based on your content, then that area will be blank. Give Google a little time to optimize it's ads for your content, then the ads will most likely show unless your forum content is so obscure that there are not many advertisers in that area.
|
#21
|
|||
|
|||
Ah thanks Mark, I realised it was because I already had a landscape banner at the top. Removing it allowed the FORUMDISPLAY banner to work.
|
#22
|
||||
|
||||
i can make as much of it into a plugin as possible if you guys want
|
#23
|
||||
|
||||
Very useful info here, thanks for the tutorial!
|
#24
|
||||
|
||||
great information - thanks for sharing this NeutralizeR...
I have tried out most of the ideas, and have settled on using the forumdisplay ads and the two for search results forumdisplay is working great, but for some reason search results just comes back with collapsible ads all the time - I cut and pasted the code exactly, so can't figure out what isn't working |
#25
|
|||
|
|||
Quote:
Quote:
|
#26
|
|||
|
|||
everything works fine except the postbitlegacy part i inserted the code but itz not displaying?
|
#27
|
|||
|
|||
Excellent post NeutralizeR
I have a small problem though.... For some reason no matter what I try, only one add will display on any page.. If I add a second one anywhere it will not appear.. Any idea what that might be? EDIT: nevermind I just now saw your explaination above... Sorry I missed it before I will wait to see if they will populate later on Thanks for the great work with this |
#28
|
|||
|
|||
Excellent article, thanks alot!
|
#29
|
|||
|
|||
If you allow search engines to spider the single versions of your posts (This post, for example... showpost.php), you may want to use adsense ads on this template, too. I think you don't want to miss any possible renevue...
Open your SHOWTHREAD_SHOWPOST template: vBulletin AdminCP > Styles & Templates > Edit Templates > Show Thread Templates > SHOWTHREAD_SHOWPOST Find: Quote:
Quote:
You can also add this code after $postbits if you want a second ad unit. |
#30
|
|||
|
|||
Quote:
I really want a plugin! Is it fare away? Marius |
#31
|
|||
|
|||
Is there a way to place the ads randomly within the ForumDisplay as opposed to the first and last post?
similar to this: http://www.aywe.com/news-announcements/ |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|