Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.5 > vBulletin 3.5 Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Adsense in last thread of search results Details »»
Adsense in last thread of search results
Version: 1.00, by AWI AWI is offline
Developer Last Online: Jun 2008 Show Printable Version Email this Page

Version: 3.5.2 Rating:
Released: 12-17-2005 Last Update: Never Installs: 23
 
No support by the author.

I saw some people asking for this so here it is...quick and painless.

In template search_results find:
Code:
<if condition="$show['ajax_js']">
	<script type="text/javascript" src="clientscript/vbulletin_ajax_threadslist.js"></script>
	<script type="text/javascript">
	<!--
	vB_AJAX_Threadlist_Init('threadslist');
	//-->
	</script>
</if>

</if>

Add below
Code:
<if condition="is_member_of($bbuserinfo, 1,2)"> 
<tr>
    <td height="60" class="alt1">
        <img src="$stylevar[imgdir_statusicon]/image.gif" alt="" border="" />    </td>
        <td height="60" align="center" class="alt2">&nbsp;</td>

    <td height="60" align="center" class="alt1">
        <div>
       **YOUR ADSENSE CODE HERE**
        </div>        
    </td>
    
    <td height="60" align="center" class="alt2 smallfont">Sponsored Link</td>

        <td height="60" align="center" class="alt1"></td>
        <td height="60" align="center" class="alt2"></td>
         <if condition="$show['inlinemod']"><td height="60" align="center" class="alt1"></td>
         </if>

</tr>
</if>

Change this line to set usergroup permission
Code:
<if condition="is_member_of($bbuserinfo, 1,2)">

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #2  
Old 12-18-2005, 07:53 PM
AWI's Avatar
AWI AWI is offline
 
Join Date: Dec 2005
Location: Midwest
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Screenshot:

Reply With Quote
  #3  
Old 12-18-2005, 09:47 PM
ugmphelon ugmphelon is offline
 
Join Date: Dec 2005
Posts: 14
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

installed
Reply With Quote
  #4  
Old 12-19-2005, 04:29 AM
Neutral Singh's Avatar
Neutral Singh Neutral Singh is offline
 
Join Date: Sep 2004
Location: Sikh Philosophy Network
Posts: 545
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for this!! How if i would like to have this as the first result in the search results? Thanks in advance.
Reply With Quote
  #5  
Old 12-19-2005, 04:55 AM
Neutral Singh's Avatar
Neutral Singh Neutral Singh is offline
 
Join Date: Sep 2004
Location: Sikh Philosophy Network
Posts: 545
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Edit: Nevemind did that myself. Thanks for a nice addon.
Reply With Quote
  #6  
Old 12-19-2005, 08:19 PM
Cebby Cebby is offline
 
Join Date: Aug 2005
Location: Pittsburgh, PA
Posts: 48
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If I want everyone to get the ad at the end of the search results, do I need the user group permission line at all?
Reply With Quote
  #7  
Old 12-19-2005, 10:07 PM
AWI's Avatar
AWI AWI is offline
 
Join Date: Dec 2005
Location: Midwest
Posts: 78
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Cebby
If I want everyone to get the ad at the end of the search results, do I need the user group permission line at all?

No just get rid of the code
Code:
<if condition="is_member_of($bbuserinfo, 1,2)">
</if>
Reply With Quote
  #8  
Old 12-20-2005, 02:53 AM
Cebby Cebby is offline
 
Join Date: Aug 2005
Location: Pittsburgh, PA
Posts: 48
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by AWI
No just get rid of the code
Code:
<if condition="is_member_of($bbuserinfo, 1,2)">
</if>
Thanks!! *Installed*
Reply With Quote
  #9  
Old 01-19-2006, 12:38 AM
murrtex murrtex is offline
 
Join Date: May 2002
Location: izmir
Posts: 249
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice,and you should add this;(bold)

Code:
        <td height="60" align="center" class="alt1"></td>
        <td height="60" align="center" class="alt2"></td>
<td height="60" align="center" class="alt1"></td>
         <if condition="$show['inlinemod']"><td height="60" align="center" class="alt1"></td>
         </if>
Reply With Quote
  #10  
Old 01-19-2006, 02:35 AM
MentaL's Avatar
MentaL MentaL is offline
 
Join Date: Jan 2003
Posts: 550
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Fanstatic INSTALLED
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 02:35 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.04384 seconds
  • Memory Usage 2,294KB
  • Queries Executed 23 (?)
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
  • (6)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (10)postbit_onlinestatus
  • (10)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
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete