PDA

View Full Version : Show Thread Enhancements - Adsense above quickreply - 2 layout versions


StarBuG
06-10-2007, 10:00 PM
Hi

To continue publishing my adsense modifications for vBulletin I have decided to release this mod as well.

What this hack does:

This hack places a google adsense leaderboard above the quick reply box in every thread.
I have two layout versions for this hack.
The first one is a in a box with a dotted border catching the attention and the second one is a simple box perfectly blending into the site.


How to install:
The dotted boarder Version:in the template "SHOWTHREAD" find:




<if condition="$show['multiquote_global']">
<script type="text/javascript" src="clientscript/vbulletin_multi_quote.js?v=$vboptions[simpleversion]"></script>
<script type="text/javascript">
var mqlimit = $vboptions[mqlimit];
</script>
</if>
and add below:



<!-- 728x90 Leaderboard below Thread above Quick Reply -->
<div style="border: 2px dashed rgb(11, 25, 140); padding: 8px; background: rgb(245, 245, 255) none repeat scroll 0% 50%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; text-align: left; font-size: 80%;">
<center>
<!-- Google Adsense Leaderboard above Quick Reply start -->
<script type="text/javascript"><!--
google_ad_client = "YOUR PUB ID HERE";
google_alternate_color = "F5F5FF";
google_ad_width = 728;
google_ad_height = 90;
google_ad_format = "728x90_as";
google_ad_type = "text";
google_color_border = "F5F5FF";
google_color_bg = "F5F5FF";
google_color_link = "000000";
google_color_text = "000000";
google_color_url = "000000";
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<!-- Google Adsense Leaderboard above Quick Reply end -->
</center>
</div><br />
<!-- 728x90 Leaderboard below Thread above Quick Reply -->
See Screenshot 1


To alter the colors of the dotted box you need to find the RGB color numbers for the color you want to use.
The first 3 numbers "rgb(11, 25, 140)" are for the border color and the second three numbers "rgb(245, 245, 255)" are for the background color.
Normaly any kind of paint program (photoshop, paint shop pro, etc) should give you the RGB numbers.
Alternatively if you are using Firefox you can install a nice plugin called: ColorZilla (https://addons.mozilla.org/en-US/firefox/addon/271)

The blended in Version:in the template "SHOWTHREAD" find:



<if condition="$show['multiquote_global']">
<script type="text/javascript" src="clientscript/vbulletin_multi_quote.js?v=$vboptions[simpleversion]"></script>
<script type="text/javascript">
var mqlimit = $vboptions[mqlimit];
</script>
</if>
and add below:



<!-- 728x90 Leaderboard below Thread above Quick Reply -->
<table class="tborder" align="center" border="0" cellpadding="6" cellspacing="1" width="100%">
<tbody><tr>
<td class="thead" align="center">
<div class="normal">
&nbsp;
</div>
</td>
</tr>
<tr>
<td class="alt1" align="center">
<div>
<center>
<!-- Google Adsense Leaderboard above Quick Reply start -->
<script type="text/javascript"><!--
google_ad_client = "YOUR PUB ID HERE";
google_alternate_color = "F5F5FF";
google_ad_width = 728;
google_ad_height = 90;
google_ad_format = "728x90_as";
google_ad_type = "text";
google_color_border = "F5F5FF";
google_color_bg = "F5F5FF";
google_color_link = "000000";
google_color_text = "000000";
google_color_url = "000000";
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<!-- Google Adsense Leaderboard above Quick Reply end -->
</center>
</div>
</td>
</tr>
</tbody>
</table>
<br />
<!-- 728x90 Leaderboard below Thread above Quick Reply -->
See Screenshot 2



You now just need to customize the adsense code marked with:

<!-- Google Adsense Leaderboard above Quick Reply start -->

replace "YOUR PUB ID HERE" with your pub-ID
and fit the colors of adsense to your color scheme



DEMO: Elternfragen.net - Das Forum f?r Eltern mit (medizinischen) Fragen (http://www.elternfragen.net)
Just view any thread


Changelog:
v1.00 - 2007/07/22: NO CHANGES, just removed my Pub-ID from the hack!


I hope you like it and if you do, don't forget to mark as installed

StarBuG

If you did not register for an Adsense account yet but you plan to, feel free to contact me. If you register via my referral I am willing to help you get the most out of your adsense placement by assisting you during the setup process and implementing the best adsense modifications. Just write me a Private message.

My other Adsense modifications:

Adsense as second post. 2 Sizes - Big for guests, small for members (https://vborg.vbsupport.ru/showthread.php?t=136743)

Adsense as second post. 2 Sizes - Big for guests, small for members - Legacy Version (https://vborg.vbsupport.ru/showthread.php?t=139093)

Adsense Link Unit in Navbar (https://vborg.vbsupport.ru/showthread.php?t=146581)

StarBuG
06-15-2007, 04:06 PM
Feedback would be realy welcome if you installed this hack ;)

CMGU
06-16-2007, 05:58 PM
excellente hack

Delphiprogrammi
06-17-2007, 08:33 PM
do not forget to change "google_ad_client" to your adsense id otherwise the coder get the earnings for this and that's probably not what you want ;):erm:

StarBuG
06-18-2007, 03:21 PM
That's basic :)

kennethsia
06-20-2007, 12:59 PM
do not forget to change "google_ad_client" to your adsense id otherwise the coder get the earnings for this and that's probably not what you want ;):erm:

good point very sneaky :D

applyimage
08-18-2007, 11:09 PM
very nice.

applyimage
08-20-2007, 06:13 PM
*installed* :) although my arn't showing up, this may be because ive only just set up adsense rather than a problem with the mod.

StarBuG
08-27-2007, 05:18 AM
If you are new to adsense this could be the case.
Adsense takes a while till it has all your pages spidered.

Also the relevancy will increase over time.

adiboy.net
09-14-2007, 09:26 AM
very nice!

red-dna
02-23-2008, 07:38 PM
Is a way to display it only in certain forums/threads ?
Maybe an "if forum=XX then display..." (i am not very good to code)
TIA