vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Adsense on the right side of a post? (https://vborg.vbsupport.ru/showthread.php?t=150195)

Ryan McBain 06-20-2007 01:57 PM

Adsense on the right side of a post?
 
How would I got about having adsense on every first post on the right side like this? http://howardforums.com/showthread.php?t=1184175

-=Sniper=- 06-20-2007 03:46 PM

In postbit_legacy or postbit template

Find
HTML Code:

<div id="post_message_$post[postid]">
Under it add

HTML Code:

<div style="float: right;>
ADSENSE CODE HERE
</div>

that should work.

Ryan McBain 06-20-2007 04:30 PM

Quote:

Originally Posted by -=Sniper=- (Post 1272537)
In postbit_legacy or postbit template

Find
HTML Code:

<div id="post_message_$post[postid]">
Under it add

HTML Code:

<div style="float: right;>
ADSENSE CODE HERE
</div>

that should work.

So this will only have the ad on the first post right?

-=Sniper=- 06-20-2007 04:33 PM

nope but this will (and only for guests)
HTML Code:

<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>


Ryan McBain 06-20-2007 04:37 PM

Thanks for the help but that didn't work

Quote:

Originally Posted by -=Sniper=- (Post 1272562)
nope but this will (and only for guests)
HTML Code:

<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>


ok lemme try it out

I do this <div id="post_message_$post[postid]">$post[message]</div>
<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>

And the code is at the bottom and it distorts the page... http://www.ryanmcbain.com/forums/showthread.php?p=20680

Hmmm am I doing something wrong?

Quote:

Originally Posted by -=Sniper=- (Post 1272562)
nope but this will (and only for guests)
HTML Code:

<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>


That's not working for me either

-=Sniper=- 06-20-2007 04:48 PM

you've not followed what I have said correctly...

replace what you posted with

HTML Code:

<div id="post_message_$post[postid]">
<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>$post[message]</div>


Ryan McBain 06-20-2007 04:55 PM

Quote:

Originally Posted by -=Sniper=- (Post 1272579)
you've not followed what I have said correctly...

replace what you posted with

HTML Code:

<div id="post_message_$post[postid]">
<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right;>
ADSENSE CODE HERE
</div></if>$post[message]</div>


Thank you, for some reason it is showing the leaderboard ads but I'll figure it out. How do I change it so every sees the ads?

-=Sniper=- 06-20-2007 04:58 PM

remove "and ($show['guest'])" if you want to show to everyone!

you need to log into google adsense to get the code for a different advert layout.

Ryan McBain 06-20-2007 05:01 PM

Quote:

Originally Posted by -=Sniper=- (Post 1272587)
remove "and ($show['guest'])" if you want to show to everyone!

you need to log into google adsense to get the code for a different advert layout.

Thanks, but I'm putting different ad layouts in there and they still give me the same one....

-=Sniper=- 06-20-2007 05:03 PM

must be doing something wrong, what code are you using?

Ryan McBain 06-20-2007 05:20 PM

Quote:

Originally Posted by -=Sniper=- (Post 1272592)
must be doing something wrong, what code are you using?

The adsense code I'm using is right... when I take out the <div style="float: right;> the right ad shows, but it shows at the very top. It has something to do with the <div style="float: right;> code

-=Sniper=- 06-20-2007 05:23 PM

try this from looking at your source
HTML Code:

<div style="float: right; width: 336px; height: 280px;">

Ryan McBain 06-20-2007 05:32 PM

That worked... thanks

Quote:

Originally Posted by -=Sniper=- (Post 1272601)
try this from looking at your source
HTML Code:

<div style="float: right; width: 336px; height: 280px;">

Does it look different to you in safari?

69lakalle 06-21-2007 08:00 AM

WORKIN FO ME


Quote:

<div id="post_message_$post[postid]">
<if condition="($post[postcount]==1) and ($show['guest'])">
<div style="float: right; width: 336px; height: 280px;">
ADSENSE CODE HERE
</div></if>$post[message]</div>


@ngel 06-23-2007 12:52 PM

Great! Works! Thanx!

cpvr 09-12-2007 01:38 AM

How do you get it to not show up on certain forums?

tutusinghsohi 09-12-2007 02:04 AM

great...thankyou...
you just spared me the time of opening a new thread asking the same question :D...

GTGT 12-20-2007 12:45 PM

It doesnt work on 3,6,8?


All times are GMT. The time now is 11:07 PM.

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.01229 seconds
  • Memory Usage 1,761KB
  • 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
  • (11)bbcode_html_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (18)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete