PDA

View Full Version : Forum Home Enhancements - Adsense Link Unit in Navbar


StarBuG
05-05-2007, 10:00 PM
I made this template mod for my medical Forum and I decided to share this with you.
This is a very efficient placement for an adsense link unit, maybe the most efficient one for a vBulletin forum

What this hack does:
This modification displays the adsense Link Unit below the forum navigation so that it looks like a second row of navigation options.

See screenshots

I have this code running for nearly a year now on my forum and google said it was ok. But to make sure you should contact google and ask them if it complies with their ToS
NO WARRANTIES ;)

How to install:

In template navbar search:

<!-- / nav buttons bar -->
and add ABOVE:

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="center" style="border-top-width:0px">
<tr align="center">
<td class="vbmenu_control">
<!-- Adsense Link Unit Code 725x15 - 5 Ads -->
<script type="text/javascript"><!--
google_ad_client = "YOUR PUB ID HERE";
google_ad_width = 728;
google_ad_height = 15;
google_ad_format = "728x15_0ads_al_s";
google_color_border = "738FBF";
google_color_bg = "738FBF";
google_color_link = "ffffff";
google_color_text = "000000";
google_color_url = "000000";
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<!-- Adsense Link Unit Code 725x15 - 5 Ads -->
</td>
</tr>
</table>
You now just need to customize the adsense code marked with:
<!-- Adsense Link Unit Code 725x15 - 5 Ads -->

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

Demo: www.elternfragen.net (http://www.elternfragen.net/)

I hope you like it.

For another good adsense placement check out my mod:

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

Please click install if you use this mod.

I also would like some feedback about how it is working out for you ;)


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


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.

croportal
05-07-2007, 06:41 PM
is this against google tos ?

StarBuG
05-07-2007, 07:05 PM
People who can read clearly have an advantage ;)


I have this code running for nearly a year now on my forum and google said it was ok. But to make sure you should contact google and ask them if it complies with their ToS
NO WARRANTIES ;)

StarBuG
05-08-2007, 05:40 PM
Let me know if it works out for you.

The money part and googles response ;)

seangworld
05-21-2007, 07:06 AM
this doesnt work. uninstalled.

StarBuG
05-21-2007, 02:29 PM
What does not work?
The code does work, if it didn't on your site then you did something wrong ;)

Big_J
05-22-2007, 03:41 PM
Nice mod, works well on my board.

Thanks

bongwater
06-03-2007, 03:47 PM
excellent, this code has many different uses and can be inserted almost anywhere where you want in the forums

StarBuG
07-06-2007, 02:47 PM
excellent, this code has many different uses and can be inserted almost anywhere where you want in the forums

That is the basic of html templates and adsense.

However other placements won't be that effective as this one ;)

iamspookysdaddy
07-15-2007, 06:19 PM
Nice Mod

Is there a way to help the adsense better reflect the content of the site.
One of my sites the eyesbehind.com is about conspiracies and that kind of content but the adsense is showing content for eye products and things like that.

Thanks :erm:

Nevermind I was impatient, I am now reflecting Aliens and all that good stuff.
Thanx:rolleyes:

StarBuG
07-16-2007, 03:44 PM
the domain eyesbehind.com is a parking site which only takes the domain name into account.
Normaly you can define keywords in your parking setup to better reflect the type of site you want to run on the parked domain.

Serkan Yılmaz
07-18-2007, 08:27 PM
Thank You

StarBuG
08-27-2007, 05:19 AM
You're welcome

Please don't forget to click Mark as Installed (http://javascript%3Cb%3E%3C/b%3E:%20vborg_doinstall%28146581,true%29)

BaHyXuH
09-27-2007, 06:40 AM
This is perfect.Installed

seangworld
10-01-2007, 07:22 AM
well it doesnt work for my site, no matter what i do with it.

seangworld
10-05-2007, 01:23 AM
i'd like to retract my statements. i finally got an email from google stating that my ads dont show up because my account was apparently suspended because i had a google-clone lol.

my account has been reinstated and so i will try this hack again. im sure it will actually work for me now...

im sorry.

seangworld
10-05-2007, 01:24 AM
actually, i already have this hack installed and that's how i knew my account was reinstated lol. god i need sleep...

cache
10-06-2007, 05:45 PM
When I tried to search the </div> and <!-- / nav buttons bar -->, I only found the <!-- / nav buttons bar -->, I don't see </div> though (see below).

I tried to insert the code above the <!-- / nav buttons bar --> but below </table>, the google
ad does not show. Am I doing anything wrong?

<!-- nav buttons bar -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="center" style="border-top-width:0px">
<tr align="center">
<if condition="$show['member']">
<td class="vbmenu_control"><a href="usercp.php$session[sessionurl_q]">$vbphrase[user_cp]</a></td>
</if>
<if condition="$show['registerbutton']">
<td class="vbmenu_control"><a href="register.php$session[sessionurl_q]" rel="nofollow">$vbphrase[register]</a></td>
</if>
$template_hook[navbar_buttons_left]
<td class="vbmenu_control"><a href="faq.php$session[sessionurl_q]" accesskey="5">$vbphrase[faq]</a></td>
<td class="vbmenu_control"><a href="memberlist.php$session[sessionurl_q]">$vbphrase[members_list]</a></td>
<td class="vbmenu_control"><a href="calendar.php$session[sessionurl_q]">$vbphrase[calendar]</a></td>
<td class="vbmenu_control"><a href="arcade.php?$session[sessionurl_q]">Arcade</a></td>
<if condition="$show['popups']">
<if condition="$show['searchbuttons']">
<if condition="$show['member']">
<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getnew" accesskey="2">$vbphrase[new_posts_nav]</a></td>
<else />
<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getdaily" accesskey="2">$vbphrase[todays_posts]</a></td>
</if>
<td id="navbar_search" class="vbmenu_control"><a href="search.php$session[sessionurl_q]" accesskey="4" rel="nofollow">$vbphrase[search]</a> <if condition="$show['quicksearch']"><script type="text/javascript"> vbmenu_register("navbar_search"); </script></if></td>
</if>
<if condition="$show['member']">
<td id="usercptools" class="vbmenu_control"><a href="$show[nojs_link]#usercptools" accesskey="3">$vbphrase[quick_links]</a> <script type="text/javascript"> vbmenu_register("usercptools"); </script></td>
</if>
<else />
<if condition="$show['searchbuttons']">
<td class="vbmenu_control"><a href="search.php$session[sessionurl_q]" accesskey="4">$vbphrase[search]</a></td>
<if condition="$show['member']">
<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getnew" accesskey="2">$vbphrase[new_posts_nav]</a></td>
<else />
<td class="vbmenu_control"><a href="search.php?$session[sessionurl]do=getdaily" accesskey="2">$vbphrase[todays_posts]</a></td>
</if>
</if>
<td class="vbmenu_control"><a href="forumdisplay.php?$session[sessionurl]do=markread" rel="nofollow">$vbphrase[mark_forums_read]</a></td>
<if condition="$show['member']">
<td class="vbmenu_control"><a href="#" onclick="window.open('misc.php?$session[sessionurl]do=buddylist&amp;focus=1','buddylist','statusbar=no,me nubar=no,toolbar=no,scroll bars=yes,resizable=yes,width=250,height=300'); return false;">$vbphrase[open_buddy_list]</a></td>
</if>
</if>
$template_hook[navbar_buttons_right]
<if condition="$show['member']">
<td class="vbmenu_control"><a href="login.php?$session[sessionurl]do=logout&amp;logouthash=$bbuserinfo[logouthash]" onclick="return log_out('$vbphrase[sure_you_want_to_log_out]')">$vbphrase[log_out]</a></td>
</if>
</tr>
</table>
<!-- / nav buttons bar -->

StarBuG
10-07-2007, 09:56 AM
just add it below the last </table> and before <!-- / nav buttons bar -->

the DIV was from an older template version which I forgot to remove.

StarBuG

Gord
10-25-2007, 01:56 PM
Very tasty. Thanks!

momo2
10-26-2007, 01:22 PM
I'm confused about something maybe someone can help me out, we are allowed 3 ads per page right ? well when this is added by the way great codes, now this will go to every pages when members are browsing and i got more adds there so when this follows it will bring it to 4 but in the main forum I'm 3 as it should be.. any advice to how to avoid the TOS

Same with the inside posts, when does the count starts ? so we got one on the nav one below nav and on my forum one on the footer which no matter where u go those will go with u.. Footer / Nav so do these 2 count for pages or since they are solid they dont count ??????

you see in the forum we have so many pages, but same headers and same footer and this is what makes the 3 ads per page confusing...

StarBuG
10-27-2007, 02:21 AM
You are allowed to have:
3 banner ads
3 link units
and unlimited referrals per page

hipgirl
11-03-2007, 11:31 PM
Thanks a lot. Marked installed.

I do have a question. Please see attached screen shot. There is a blue line between navbar menu and google ads (where the arrow points). Could you help me remove it?

I used the 4 ads unit instead of 5 because the font size are the same as menu. I have to change the google ad width from 728 to 770 so the 4 ad unit will spread evenly (1 under 'new post' and 1 under 'quick links'.

Thanks again.

Michelle
www.hipgirlclips.com/forums

StarBuG
11-04-2007, 09:39 AM
You can't change the google ad width, that is not allowed!
They have a fixed width

hipgirl
11-05-2007, 03:44 AM
Thank you. I changed the width back.

In your snap shot, there is no line between nav bar menu and the adsend link unit. But I have a blue line. I'm not sure how to remove it. Could you help?

Thanks a lot.

Michelle

StarBuG
11-06-2007, 04:05 PM
I think that this is defined by the border color you set in your style.
I have the exact same code implemented into my forum.

StarBuG

csavern
11-12-2007, 12:51 PM
When i put this code in for some reason it centers the everything on the forum
i cant have everything centered is there away to change this

StarBuG
11-12-2007, 01:47 PM
You probably forgot to close my table.
Check the code again you entered.

Or you removed a </div>

If everything fails, restore the template to its original and try it again.

AmbitiousOne
12-15-2007, 08:47 AM
This is where I put mine.

http://2kfreak.com/forums/index.php

I dont' see why I would need to contact google of TOS. This is clearly a "read" issue. If the use his/her eyes, no reason to get punished for wrongful clicking.

ivanstanchev
03-22-2008, 08:19 PM
Is this safe ?

montsa007
07-04-2008, 06:38 AM
Excellent mod, this is sure to increase your adsense by leaps and ounds.
*Installed*