vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=155)
-   -   Adsense Under First Posts - Clean (https://vborg.vbsupport.ru/showthread.php?t=116593)

Boguns 05-23-2006 10:00 PM

Adsense Under First Posts - Clean
 
This mod ads a simple google adsense advertisement below the first post in your forum.

The advantage of this is if you do not want to clutter up your forum with a big table etc.

Working Demo: http://discusscareers.com/

Installation Time: 1 min
Easy.

Insert this code at the very END of your postbit_legacy template

PHP Code:

$spacer_open
       
        
<div align="center">

                         <!--
ADSENSE CODE BELOW -->

        </
div>
        
$spacer_close
<br


Boguns 05-24-2006 09:25 PM

Here is a screenshot

Pathor 05-24-2006 10:01 PM

Code:

$spacer_open
     
        <div align="center">

                        <!--ADSENSE CODE BELOW -->

        </div>
       
$spacer_close
<br />

;)

Roms 05-24-2006 10:08 PM

Quote:

Originally Posted by Pathor
Code:

$spacer_open
 
        <div align="center">
 
                        <!--ADSENSE CODE BELOW -->
 
        </div>
 
$spacer_close
<br />

;)

<br /> or <BR> isn't really a big deal....... ;)

Back in the day they tought everyone to use all caps too... :p

akanevsky 05-24-2006 10:18 PM

Quote:

Originally Posted by Infantrymen
<br /> or <BR> isn't really a big deal....... ;)

Back in the day they tought everyone to use all caps too... :p

Yes it is, because vBulletin is mostly XHTML-compliant. :)
As for caps, that is ancient history :)

SixteenOhNine 05-24-2006 10:28 PM

While <br> and <br /> will work the same, one will validate and one won't. Given you are one of the many that wishes to maintain validity throughout your website, you'd need to use <br /> :).

Roms 05-24-2006 10:30 PM

Quote:

Originally Posted by Psionic Vision
Yes it is, because vBulletin is mostly XHTML-compliant. :)
As for caps, that is ancient history :)

Tells you how "old school" I am. Good to know. :)

akanevsky 05-24-2006 11:03 PM

Quote:

While <br> and <br /> will work the same, one will validate and one won't. Given you are one of the many that wishes to maintain validity throughout your website, you'd need to use <br /> .
Didn't you mean "of the few"?

Freesteyelz 05-24-2006 11:25 PM

Let's take it one step further then, shall we :) :

Code:

$spacer_open
        <div style="text-align:center">
                        <!--ADSENSE CODE BELOW -->
        </div>
$spacer_close
<br />


Living in music 05-25-2006 01:02 AM

Lolz!

Kaleem 05-25-2006 02:36 AM

thanks man i didt like the random one that we have it already on the forum

Snake 05-25-2006 07:12 PM

Thanks for this man! :)

tgreer 05-25-2006 07:23 PM

Also, Google Adsense uses "documet.write()", which isn't part of the XHTML specification. So while I agree that one should use "<br />", since this is a Google Adsense hack, it's pointless to try to be XHTML-valid in the first place.

mathias 05-25-2006 09:07 PM

it post the ad under every post.... Is it just supposed to be first?

azn_romeo_4u 05-26-2006 07:08 AM

this mod does not work. It ads it under every post. Viewsource and you will see the adsense ad code multiple times. This is against Adsense TOS.

nymyth 06-13-2006 01:13 PM

^^adding it under each post for me too.....any ideas??

Peace

Netdesignz 06-14-2006 09:59 AM

Great Mod. Worked for me and only puts ads after first post.
Installed :)

UZFRED 06-14-2006 04:49 PM

Very nice mod!

But I have one problem. I got this installed without problems on 2 custom templates, but on the default template the following problem occurs:

https://vborg.vbsupport.ru/attachmen...1&d=1150307264

A grey space appears underneath it.

Can anybody please help me!

I have no other template modifications, I hope there is a fix for it.

neologan 06-18-2006 06:17 PM

adds it under every post for me too...

patrickstar 06-20-2006 12:26 AM

i get it under the first two post.

????

patrickstar 06-20-2006 12:40 AM

ok got it to work, looks great. thanks.

dont know if anyone was doing what i did wrong but i had to make sure i removed all of this: <!--ADSENSE CODE BELOW -->

ReadOrDie 07-21-2006 01:41 AM

Finally! A code that works! There's about four things I've tried in this forum that don't work at all, it seems as though the creators don't bother testing their hacks before they post them. Is there a way to have it display under each post instead of just one?

GoTTi 07-22-2006 08:20 PM

why when using firefox, and there is a new post done after the first post and the banner shows, does the page reload to a white page and never show the thread?

Wills123 07-25-2006 09:39 AM

Hi

I have just loaded this onto my website (www.newbusinessportal.co.uk), but the ads aren't showing. Is this because it takes a while for google to realise that you have added the code?

Thanks

Will

odessa 06-15-2011 07:22 PM

work in the first and the seconds !!
i need only under First Posts?


All times are GMT. The time now is 05:55 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.01180 seconds
  • Memory Usage 1,763KB
  • 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
  • (3)bbcode_code_printable
  • (1)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (25)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