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 in last thread of search results (https://vborg.vbsupport.ru/showthread.php?t=103236)

AWI 12-17-2005 10:00 PM

Adsense in last thread of search results
 
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)">

AWI 12-18-2005 07:53 PM

Screenshot:

http://www.dntycoon.com/images/capture.jpg

ugmphelon 12-18-2005 09:47 PM

installed

Neutral Singh 12-19-2005 04:29 AM

Thanks for this!! How if i would like to have this as the first result in the search results? Thanks in advance.

Neutral Singh 12-19-2005 04:55 AM

Edit: Nevemind did that myself. Thanks for a nice addon.

Cebby 12-19-2005 08:19 PM

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?

AWI 12-19-2005 10:07 PM

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>


Cebby 12-20-2005 02:53 AM

Quote:

Originally Posted by AWI
No just get rid of the code
Code:

<if condition="is_member_of($bbuserinfo, 1,2)">
</if>


Thanks!! *Installed*

murrtex 01-19-2006 12:38 AM

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>


MentaL 01-19-2006 02:35 AM

Fanstatic INSTALLED


All times are GMT. The time now is 04: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.01840 seconds
  • Memory Usage 1,735KB
  • 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
  • (6)bbcode_code_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete