The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
A Neater Google Adsense After First Post Details »» | |||||||||||||||||||||||||||
Ok, so i haven't found any google adsence products for vb 4 yet that sit neatly under your first post only, on every page. Credits to Miko and my self for a few tiny edits.
How To Install Step.1: GoTo Postbit Templates>>open postbit_legacy and add at the very bottom: Code:
<vb:if condition="$post['isfirstshown']"> <li class="firstpost_advert_container"><div class="firstpost_advert"> REPLACE THIS WITH YOUR ADSENSE CODE HERE </div> </li> </vb:if> Step.2: GoTo CSS Templates>>open additional.css and add this code: Code:
.firstpost_advert_container { clear: both; display: block; float: left; margin-bottom: 12px; position: relative; width: 100%; border: 1px solid #E5E6F4; } .firstpost_advert { with: 100%; background: #F1F1FA; border: 1px solid #fff; min-height: 90px; margin: 0; padding: 7px; text-align: center; vertical-align: middle; } DEMO: Teen Forums Please Note: im not a coder, i just wanted to share this with others, its VERY easy to add to your styles and looks neat. Good Luck. This coding is also different than Mod Version: 1.00, by Allan. You shouldn't have any problems with this and it will do you till a product version comes out. Screenshots
Show Your Support
|
5 благодарности(ей) от: | ||
acmalin927, farru, sodasusu, SolidSnakeLive, StormBreaker |
Comments |
#22
|
|||
|
|||
Brilliant, thank you.
|
#23
|
|||
|
|||
How to add advertisement after last post on the page? It's simple
DEMO here. You have to make a small change in the pasted code in Postbit Legacy Template (postbit_legacy) (on the color green). Code:
<vb:if condition="$post['islastshown']"> <li class="firstpost_advert_container"><div class="firstpost_advert"> REPLACE THIS WITH YOUR ADSENSE CODE HERE </div> </li> </vb:if> If you want to have two advertisements simultaneously, the advertisement after the first post and the one after the last, paste this into the previous one. Postbit Legacy Template (postbit_legacy) should look like this (paste this code at the end): Code:
<vb:if condition="$post['isfirstshown']"> <li class="firstpost_advert_container"><div class="firstpost_advert"> REPLACE THIS WITH YOUR ADSENSE CODE HERE </div> </li> </vb:if> <vb:if condition="$post['islastshown']"> <li class="firstpost_advert_container"><div class="firstpost_advert"> REPLACE THIS WITH YOUR OTHER ADVERTISEMENT CODE HERE </div> </li> </vb:if> When using this code, advertisement after the last post using the same code CSS Template (additional.css) for the first advertisement. Don't change anything in CSS Template. But when changing CSS Template for second advertisement (after last post) must add this code to CSS Template (paste at the end in additional.css) Code:
.lastpost_advert_container { clear: both; display: block; float: left; margin-bottom: 12px; position: relative; width: 100%; border: 1px solid #E5E6F4; } .lastpost_advert { with: 100%; background: #F1F1FA; border: 1px solid #fff; min-height: 90px; margin: 0; padding: 7px; text-align: center; vertical-align: middle; } and change in Postbit Legacy this green text: Code:
<vb:if condition="$post['isfirstshown']"> <li class="firstpost_advert_container"><div class="firstpost_advert"> REPLACE THIS WITH YOUR ADSENSE CODE HERE </div> </li> </vb:if> <vb:if condition="$post['islastshown']"> <li class="lastpost_advert_container"><div class="lastpost_advert"> REPLACE THIS WITH YOUR OTHER ADVERTISEMENT CODE HERE </div> </li> </vb:if> DEMO here. Happy New Year |
#24
|
|||
|
|||
Tagged this. For ad in the last post.:up:
|
#25
|
|||
|
|||
Thank you. Added with edits for groups in post #11. Works great.
|
#26
|
|||
|
|||
Hi Guys, not sure what I'm doing wrong, but can't get anything to display (in either first post or last post)..
This is the bottom of my postbit_legacy template Am I missing something? I've also modded the additional.css templates... I'm using 4.1.0 Patch Level 2, any help appreciated. UPDATE: Ok, so I have this running ok one on board, but the other it only shows if I'm logged out... Obviously something to do with permissiong... Any help still appreciated! |
#27
|
|||
|
|||
Tagged. Might come useful
|
#28
|
|||
|
|||
Quote:
I would say something to do with permissioning, but can't find out where :-) |
#29
|
|||
|
|||
very nice share thank you
|
#30
|
||||
|
||||
Very good one, tagged.
|
#31
|
|||
|
|||
It displays the adsense on the first post, of each page correct? Like, if the thread has multiple pages, does it still show up?
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|