PDA

View Full Version : Banner in header and then one after first post?


Brent
12-20-2005, 05:46 AM
I currently have a banner in the header that goes across the whole site.

I want to also add a the same rotating banner after the first post of a thread. How do I do so? If I use $GAB_ads[0] which is the same as the one in the header nothing shows.

Thanks

The Geek
12-20-2005, 11:04 AM
There is no way to do this by default right now, however ill put together a quick mod for you later today.

Brent
12-20-2005, 07:51 PM
Thanks! :)

The Geek
12-20-2005, 10:31 PM
Ok, I was just playing about, so Im not 100% sure if this will work - but give it a try and let me know.

Create a new plugin:
Hook Location: postbit_display_complete
Title: GAB ad after first post
code:

global $GAB_ads, $counter;
if ($counter == 1)
{
$GAB_fp=$GAB_ads[X];
}
else
{
$GAB_fp ="";
}


NOTE: the x in $GAB_ads[X] above is the number of the ad block (ie 0 or 1 or 2 or whatever).

Then edit your postbit template and put:

$GAB_fp

above:

<if condition="$show['spacer']">
</div>
$spacer_close
</if>
<!-- / post #$post[postid] -->


Note that those are the last lines in the template.

Like I said, I havent really tested it - however in theory it SHOULD work :)

Let me know.

Brent
12-21-2005, 07:01 AM
Works! Thanks