Need to put adsense ads after the first post in phpBB

Discussion in 'vBulletin' started by nicedeals, Oct 17, 2006.

  1. #1
    As the tilte says..can anyone guide me on how to put adsebse ads just after the first post in phpBB. It seems to get repeated for the second, third post aswell when I paste the adsense code in viewtopic_body.tpl

    Is this area shown below relevant;

    {POLL_DISPLAY}
    <tr>
    <th class="thLeft" width="150" height="26" nowrap="nowrap">{L_AUTHOR}</th>
    <th class="thRight" nowrap="nowrap">{L_MESSAGE}</th>
    </tr>
    <!-- BEGIN postrow -->
    <tr>
    <td width="150" align="left" valign="top" class="{postrow.ROW_CLASS}"><span class="name"><a name="{postrow.U_POST_ID}"></a><b>{postrow.POSTER_NAME}</b></span><br /><span class="postdetails">{postrow.POSTER_RANK}<br />{postrow.RANK_IMAGE}{postrow.POSTER_AVATAR}<br /><br />{postrow.POSTER_JOINED}<br />{postrow.POSTER_POSTS}<br />{postrow.POSTER_FROM}</span><br /></td>
    <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
    <tr>
    <td width="100%"><a href="{postrow.U_MINI_POST}"><img src="{postrow.MINI_POST_IMG}" width="12" height="9" alt="{postrow.L_MINI_POST_ALT}" title="{postrow.L_MINI_POST_ALT}" border="0" /></a><span class="postdetails">{L_POSTED}: {postrow.POST_DATE}<span class="gen">&nbsp;</span>&nbsp; &nbsp;{L_POST_SUBJECT}: {postrow.POST_SUBJECT}</span></td>
    <td valign="top" nowrap="nowrap">{postrow.QUOTE_IMG} {postrow.EDIT_IMG} {postrow.DELETE_IMG} {postrow.IP_IMG}</td>
    </tr>
    <tr>
    <td colspan="2"><hr /></td>
    </tr>
    <tr>
    <td colspan="2"><span class="postbody">{postrow.MESSAGE}{postrow.SIGNATURE}</span><span class="gensmall">{postrow.EDITED_MESSAGE}</span></td>
    </tr>
    </table></td>
    </tr>
    <tr>
    <td class="{postrow.ROW_CLASS}" width="150" align="left" valign="middle"><span class="nav"><a href="#top" class="nav">{L_BACK_TO_TOP}</a></span></td>
    <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="bottom" nowrap="nowrap"><table cellspacing="0" cellpadding="0" border="0" height="18" width="18">
    <tr>
    <td valign="middle" nowrap="nowrap">{postrow.PROFILE_IMG} {postrow.PM_IMG} {postrow.EMAIL_IMG} {postrow.WWW_IMG} {postrow.AIM_IMG} {postrow.YIM_IMG} {postrow.MSN_IMG}<script language="JavaScript" type="text/javascript"><!--

    if ( navigator.userAgent.toLowerCase().indexOf('mozilla') != -1 && navigator.userAgent.indexOf('5.') == -1 && navigator.userAgent.indexOf('6.') == -1 )
    document.write(' {postrow.ICQ_IMG}');
    else
    document.write('</td><td>&nbsp;</td><td valign="top" nowrap="nowrap"><div style="position:relative"><div style="position:absolute">{postrow.ICQ_IMG}</div><div style="position:absolute;left:3px;top:-1px">{postrow.ICQ_STATUS_IMG}</div></div>');

    //--></script><noscript>{postrow.ICQ_IMG}</noscript></td>
    </tr>
    </table></td>
    </tr>
    <tr>
    <td class="spaceRow" colspan="2" height="1"><img src="templates/subSilver/images/spacer.gif" alt="" width="1" height="1" /></td>
    </tr>
    <!-- END postrow -->

    Thanks!
     
    nicedeals, Oct 17, 2006 IP
  2. Endurer

    Endurer Well-Known Member

    Messages:
    1,113
    Likes Received:
    84
    Best Answers:
    0
    Trophy Points:
    140
    #2
    Here is a mod that will let you do just that. You can also use Dave Taylor's method as well but that mod above gives you more control. You can exclude forums, usergroups right from your ACP.
     
    Endurer, Oct 17, 2006 IP
    nicedeals likes this.
  3. maxsmuter

    maxsmuter Peon

    Messages:
    138
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #3
    thanks "endurer" fo the mod, even I needed something like that.
     
    maxsmuter, Oct 17, 2006 IP
  4. kingrage

    kingrage Peon

    Messages:
    559
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    0
  5. oseymour

    oseymour Well-Known Member

    Messages:
    3,960
    Likes Received:
    92
    Best Answers:
    0
    Trophy Points:
    135
    #5
    Can anyone tell me how to do this with Vbulletin?
     
    oseymour, Oct 26, 2006 IP
  6. Endurer

    Endurer Well-Known Member

    Messages:
    1,113
    Likes Received:
    84
    Best Answers:
    0
    Trophy Points:
    140
    #6
    Edit your postbit template from the AdminCP:

    ADD this code at the very end of postbit:

    <if condition="$post[postcount] % $vboptions[maxposts] == 1">
    
    <div style="padding: $stylevar[cellpadding]px 0px 0px 0px">
    
    <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
    <tr>
    	<td class="thead" align="left">Sponsored Links</td>
    </tr>
    <tr>
    	<td class="alt1" align="center">
    		BANNER CODE HERE
    	</td>
    </tr>
    </table>
    
    </div>
    
    </if>
    Code (markup):
    Replace the BANNER CODE HERE with your adsense code. More conditions are availavle Here
     
    Endurer, Oct 26, 2006 IP