The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
![]() |
|||||||||||||||||||||||||||
"In reply to" Hack (threaded info for linear users)
![]() Developer Last Online: Sep 2014 ![]() ![]()
vB3.0/hack version "frozen"; vB3.5/plugin version released
You can get the plugin for vb3.5 here. There will be no more releases for the vB3.0 version. Description This hack allows the display of the title and author of the post that each post is in response to. (See screenshot if clarification is needed) The purpose of this hack is to provide missing information to linear view mode users. I got the idea from a board I visit that used to be UBB Threads, though my choice of presentation is a bit different. See the attached screenshot for an example of how this can look. The hack itself only provides the additional items in $post, so it is up to the templates exactly how it looks. (The changes I used are included as an example in the hack instructions) Complexity This hack changes one file, requires no queries, and requires changes to one template. Technical This hack has been tested on vB3.0.3,vB3.0.0RC4 and vB3.0.0RC2. It adds 1 query to showthread in linear mode, and adds 1 additional query in linear mode for each consecutive layer of deleted parents of posts displayed on a page. (If a displayed post is a reply to a deleted reply to an undeleted reply to a deleted reply to an undeleted post, 2 total queries are added to showthread, but if a displayed post is a reply to a deleted reply to a deleted reply to a deleted reply to an undeleted post, 4 total queries are added to showthread. If both examples are displayed in the same page, only 4 total queries are added to showthread.) Update (v1.10 2004-03-01) Version 1.10 released, which uses the beginning of a post as a title if the post does not have a title, and also trims long titles down to a decent size. Minor optimizations. regardinghackupdate.txt added for existing users, regardinghack.txt updated for new users. Support Please click the install button above if you install this hack. The hack version of this modification will have no further updates, but I will still answer questions in this thread. Show Your Support
|
Comments |
#22
|
|||
|
|||
![]()
OK, I'm not sure I understand the template part, where exactly does this need to be added in the postbit template, and is that all that is needed there?
<if condition="isset($post['re_postid'])"> Posted in reply to <if condition="$post['re_userid']"><a href="member.php?userid=$post[re_userid]">$post[re_username]</a><else />$post[re_username]</if>'s <if condition="$post['re_tittype']!=0">post <if condition="$post['re_tittype']==2">starting</if></if> <a href="$post[re_url]" <if condition="!$post['re_isonpage']">target="_blank"</if>><if condition="$post['re_tittype']==0">untitled post<else />"$post[re_title]"</if></a> </if> I get a Parse error: parse error, unexpected T_LIST on line 862? I could have easy messed something up. ![]() |
#23
|
||||
|
||||
![]()
Well, that looks right; maybe you accidentally pasted it in the middle of something. The where depends on preference and what you've already done to your postbit. In the case of my example image, you would search for
Code:
<if condition="$show['postcount']">#<a href="showpost.php?$session[sessionurl]p=$post[postid]&postcount=$post[postcount]" target="new"><strong>$post[postcount]</strong></a></if> Code:
<if condition="isset($post['re_postid'])"> <span class="smallfont" style="float:left;"> Posted in reply to <if condition="$post['re_userid']"><a href="member.php?userid=$post[re_userid]">$post[re_username]</a><else />$post[re_username]</if>'s <if condition="$post['re_tittype']!=0">post <if condition="$post['re_tittype']==2">starting</if></if> <a href="$post[re_url]" <if condition="!$post['re_isonpage']">target="_blank"</if>><if condition="$post['re_tittype']==0">untitled post<else />"$post[re_title]"</if></a> </span> </if> Code:
<!-- message --> Code:
<if condition="isset($post['re_postid'])"> [Re: <a href="$post[re_url]" target="_blank">$post[re_username]</a>] </if> If you still have trouble with this, you can ICQ me. |
#24
|
|||
|
|||
![]()
OK, I am getting somewhere now, I re-edited the showthread.php and it works fine, here is what I have so far on my test site:
http://coloradok5.com/vbtestforums/s...d.php?t=123105 I want it to act just like the forum below: http://www.world-a-team.com/showthread.php?t=1720 I can't quite get the code right to remove the old Re: title setup, I know it involves this code I think: ---------------------------------------------------------------- <!-- icon and title --> <div class="smallfont"> <if condition="$show['messageicon']"><img class="inlineimg" src="$post[iconpath]" alt="$post[icontitle]" border="0" /></if> <if condition="$post['title']"><strong>$post[title]</strong></if> </div> <hr size="1" style="color:$stylevar[tborder_bgcolor]" /> <!-- / icon and title --> ---------------------------------------------------------------- Any ideas? Also, what is the best way to handle the reply button on every post like http://www.world-a-team.com has? Thanks for the help. |
#25
|
||||
|
||||
![]()
I can't access your test forum to tell you how to remove whatever, but I can tell you that to place the reply information like world-a-team.com, you should find
Code:
<div class="normal"> <!-- status icon and date --> <a name="post$post[postid]"><img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" /></a> <if condition="!$show['announcement']"> $post[postdate]<if condition="!$show['detailedtime']">, $post[posttime]</if> <else /> <phrase 1="$post[startdate]" 2="$post[enddate]">$vbphrase[x_until_y]</phrase> </if> $post[firstnewinsert] <!-- / status icon and date --> </div> Code:
<div class="normal" style="float:$stylevar[left];width:14em"> <!-- status icon and date --> <a name="post$post[postid]"><img class="inlineimg" src="$stylevar[imgdir_statusicon]/post_$post[statusicon].gif" alt="$post[statustitle]" border="0" /></a> <if condition="!$show['announcement']"> $post[postdate]<if condition="!$show['detailedtime']">, $post[posttime]</if> <else /> <phrase 1="$post[startdate]" 2="$post[enddate]">$vbphrase[x_until_y]</phrase> </if> $post[firstnewinsert] <!-- / status icon and date --> </div> <if condition="isset($post['re_postid'])"> <div class="normal"> Posted in reply to <strong><if condition="$post['re_userid']"><a href="member.php?userid=$post[re_userid]">$post[re_username]</a><else />$post[re_username]</if></strong>'s <if condition="$post['re_tittype']!=0">post <if condition="$post['re_tittype']==2">starting</if></if> <a href="$post[re_url]" <if condition="!$post['re_isonpage']">target="_blank"</if>><if condition="$post['re_tittype']==0">untitled post<else />"$post[re_title]"</if></a> </div> </if> http://mydomain.com/forum/newreply.php?do=newreply&p=478835 becomes http://mydomain.com/forum/newreply.php?do=newreply&p=478835&noquote=1 [/edit] |
#26
|
|||
|
|||
![]() Quote:
Code:
<!-- controls --> <if condition="THIS_SCRIPT=='showthread' and !is_browser('opera') and $post['editlink'] and $bbuserinfo[userid]>0"> $quickedit </if> <if condition="$post['editlink']"> <a href="$post[editlink]"><img border='0' src='$stylevar[imgdir_button]/edit.gif' alt='$vbphrase[edit_delete_message]' /></a></if> <if condition="$SHOWQUICKREPLY AND !$show['threadedmode']"> <a href="$post[replylink]" onclick="return qr($post[postid]);"><img border='0' src='$stylevar[imgdir_button]/quickreply.gif' alt='$vbphrase[quick_reply_to_this_message]' /></a></if> <if condition="$post['forwardlink']"> <a href="$post[forwardlink]"><img border='0' src='$stylevar[imgdir_button]/forward.gif' alt='$vbphrase[forward_message]' /></a></if> <if condition="$post['replylink']"> <a href="$post[replylink]&noquote=1"><img border='0' src='$stylevar[imgdir_button]/reply_small.gif' alt='$vbphrase[reply]' /></a></if> <if condition="$post['replylink']"> <a href="$post[replylink]"><img border='0' src='$stylevar[imgdir_button]/quote.gif' alt='$vbphrase[reply_with_quote]' /></a></if> <img src="$stylevar[imgdir_button]/mq_img_off.gif" alt="$vbphrase[multi_quote]" border="0" width="13" height="13" name="mq_post_$post[postid]" id="mq_post_$post[postid]" onclick="multiquote($post[postid], this)" style="cursor: hand" /> <!-- / controls --> Code:
<!-- controls --> <if condition="$post['editlink']"> <a href="$post[editlink]"><img src="$stylevar[imgdir_button]/edit.gif" alt="$vbphrase[edit_delete_message]" border="0" /></a> </if> <if condition="$post['forwardlink']"> <a href="$post[forwardlink]"><img src="$stylevar[imgdir_button]/forward.gif" alt="$vbphrase[forward_message]" border="0" /></a> </if> <if condition="$post['replylink']"> <a href="$post[replylink]"><img src="$stylevar[imgdir_button]/<if condition="$post['forwardlink']">reply_small<else />quote</if>.gif" alt="$vbphrase[reply_with_quote]" border="0" /></a> </if> <if condition="$SHOWQUICKREPLY AND !$show['threadedmode']"> <a href="$post[replylink]" onclick="return qr($post[postid]);"><img src="$stylevar[imgdir_button]/quickreply.gif" alt="$vbphrase[quick_reply_to_this_message]" border="0" /></a> </if> <!-- / controls --> |
#27
|
|||
|
|||
![]() Quote:
Code:
<if condition="isset($post['re_postid'])"> Posted in reply to <if condition="$post['re_userid']"><strong>$post[re_username]</strong><else />$post[re_username]</if>'s <if condition="$post['re_tittype']!=0">post <if condition="$post['re_tittype']==2">starting</if></if> <a href="$post[re_url]" <if condition="!$post['re_isonpage']">target="_blank"</if>><if condition="$post['re_tittype']==0">untitled post<else />"$post[re_title]"</if></a> </if> |
#28
|
|||
|
|||
![]() Quote:
My server is up now, I didn't want to power up, always something. |
#29
|
|||
|
|||
![]() Quote:
Thanks, I think I have it. Looking at your site, it looks like if someone replies to a post and does not change the title the original title does not get outputed, how ddi you do that? |
#30
|
||||
|
||||
![]()
Do you mean the option
Automatically Quote Post / Thread Title in Message posting and eding options? |
#31
|
|||
|
|||
![]()
No, just like how he got rid of the default "re title name" if it didn't change:
Example http://www.world-a-team.com/showthread.php?t=1720 Notice how on the first post the default title is displayed: "Current ICC OneDay Championship Table - 5th December 2004" Then on the following posts they are not, yet on post #6 the user changed the title to: "Zimbabwe / Zimbabyou" and it now displays without the icon. That is what I would like to do if I could. :up: |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|