Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Google Adsense after first post (or other advertisements) Details »»
Google Adsense after first post (or other advertisements)
Version: 1.00, by Allan Allan is offline
Developer Last Online: Mar 2017 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 4.0.0 Rating:
Released: 12-31-2009 Last Update: Never Installs: 148
Template Edits
 
No support by the author.

With this mod, you can add an advertisement as Google Adsence or other advertisements.
  • In the "postbit" or "postbit_legacy", add to the end:
Code:
<vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '1')">
  <div class="attachments">
        <div style="width: 100%; text-align: center">
       Your text here
      </div>
</div>
</vb:if>
  • 2nd method, in the "ad_showthread_firstpost" template, add:
Code:
  <div class="attachments">
        <div style="width: 100%; text-align: center"> 
Your text here       
        </div>
  </div>
PS: I use class "attachments", it's just for the fun ^^

Screenshots

File Type: jpg pub1.jpg (80.6 KB, 0 views)
File Type: jpg pub2.jpg (72.7 KB, 0 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Благодарность от:
sodasusu

Comments
  #12  
Old 01-08-2010, 02:01 PM
meissenation meissenation is offline
 
Join Date: Apr 2005
Posts: 476
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by haluk View Post
How Can I add an ad after second or third posts ?

Is there a way ?
Change:
<vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '1')">

to:
<vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '2')">
-or-
<vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '3')">

respectively.
Reply With Quote
  #13  
Old 01-08-2010, 04:42 PM
albrens albrens is offline
 
Join Date: Jun 2006
Location: AU
Posts: 39
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you

But there a blank speac

Have look

http://upload.traidnt.net/upfiles/Sg776678.png
Reply With Quote
  #14  
Old 01-08-2010, 07:46 PM
atgv atgv is offline
 
Join Date: Dec 2007
Posts: 12
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

reserved
Reply With Quote
  #15  
Old 01-10-2010, 02:36 PM
Gene Steinberg Gene Steinberg is offline
 
Join Date: Dec 2006
Posts: 278
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How about a method to reduce the width to the normal maximum of 728pixels, and then center that object without the gray border? Or just eliminate the gray background?

How is that done?

Also is there a code to have it go after the 1st and 4th posts and perhaps the last post too?

Peace,
Gene
Reply With Quote
  #16  
Old 01-14-2010, 04:46 PM
SpongeBob71 SpongeBob71 is offline
 
Join Date: Mar 2008
Posts: 32
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does anyone else have the issue of NOT having a space between the end of the first thread and the mods grey box? Mine is stuck together and does not have the space.

I have 4.1.

-SB
Reply With Quote
  #17  
Old 01-16-2010, 03:33 AM
cagbaazee cagbaazee is offline
 
Join Date: Jul 2007
Posts: 179
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I donot find the code here... please discuss
Reply With Quote
  #18  
Old 01-16-2010, 06:45 AM
justhackerz justhackerz is offline
 
Join Date: Dec 2009
Posts: 6
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I got alot of Error with this try to Fix it to work with AdBrite.
Reply With Quote
  #19  
Old 01-16-2010, 08:24 AM
Cableguy69 Cableguy69 is offline
 
Join Date: Apr 2008
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Gene Steinberg View Post
How about a method to reduce the width to the normal maximum of 728pixels, and then center that object without the gray border? Or just eliminate the gray background?

How is that done?

Also is there a code to have it go after the 1st and 4th posts and perhaps the last post too?

Peace,
Gene
Quote:
Originally Posted by SpongeBob71 View Post
Does anyone else have the issue of NOT having a space between the end of the first thread and the mods grey box? Mine is stuck together and does not have the space.

I have 4.1.




-SB
Method 1

PHP Code:
<br \>
<
vb:if condition="(THIS_SCRIPT == showthread) AND ($post[postcount] == '1')">
  <
div class="body">
        <
div style="width: 100%; text-align: center">
        <
a href="ink to ad"><img src="http://your-ad-image-link.com" width="728"></a>
      </
div>
</
div>
</
vb:if> 
Method 2

PHP Code:
  <br \>
         <
div class="body">
        <
div style="width: 100%; text-align: center"
        <
a href="ink to ad"><img src="http://your-ad-image-link.com" width="728"></a>       
        </
div>
  </
div


Both methods above will make a space get rid of the border and resize the images to 728px wide.

if you want to resize the height you should add height="X" (change x to your own value)

EG: <img src="http://your-ad-image-link.com" width="728" height="75">

The grey border is caused by <div class="attachments"> so in my examples I've changed it to <div class="body"> to make the border disappear.
Reply With Quote
  #20  
Old 01-16-2010, 04:58 PM
barcena's Avatar
barcena barcena is offline
 
Join Date: Sep 2006
Posts: 262
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I used the first option

Quote:
?In the "postbit" or "postbit_legacy", add to the end:
Where it says Enter Text i did enter the Ad HTML code... Is that right?

I can't see anything so far between posts or in any place at all, what I'm doing wrong please?
Reply With Quote
  #21  
Old 01-16-2010, 05:29 PM
barcena's Avatar
barcena barcena is offline
 
Join Date: Sep 2006
Posts: 262
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Id manage, my mistake, was entering the code after the very ending after the raw thing, sorry i'm not coder at all.

Now, if I can just get rid of those white areas will be a blessing.
Attached Images
File Type: jpg Ad system.jpg (20.3 KB, 0 views)
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:59 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04644 seconds
  • Memory Usage 2,352KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_code
  • (2)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (1)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (3)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete