Version: 1.00, by Johannes de Le?n
Developer Last Online: Aug 2006
Version: 3.5.0 RC2
Rating:
Released: 06-29-2005
Last Update: Never
Installs: 76
DB Changes Uses Plugins Template Edits
No support by the author.
This is a port of: https://vborg.vbsupport.ru/showthread.php?t=61222
(ported with permission)
Who viewed this thread? This hack shows who has viewed any thread. View the screenshot to see how it looks.
Details 1 Query
1 New Phrase
1 Template Edit
1 Plugin XML
Screenshots
Available here, though now the box appears below the Current Active Users instead of above the post reply button, and it is not collapsible anymore.
Credits
Gary King, for allowing me to port his hack.
-----------
Instructions
Run query [sql]ALTER TABLE thread ADD whoviewed TEXT NOT NULL;[/sql]
Create new phrase
already_viewed_this_thread / Already viewed this thread:
Edit template
Open SHOWTHREAD and find:
HTML Code:
<!-- currently active users --><if condition="$show['activeusers']"><table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"><tr><td class="tcat" colspan="2"><phrase 1="$totalonline" 2="$numberregistered" 3="$numberguest">$vbphrase[users_viewing_this_thread_x_y_z]</phrase></td></tr><tr><td class="alt1" colspan="2"><span class="smallfont">$activeusers</span></td></tr></table></if><!-- currently active users -->
Below this add:
HTML Code:
<!-- who viewed this thread --><br /><table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"><tr><td class="tcat" colspan="2">
$vbphrase[already_viewed_this_thread]
</td></tr><tr><td class="alt1" colspan="2"><span class="smallfont">$thread[viewers]</span></td></tr></table><!-- who viewed this thread -->
Plugin
Just upload it, and it's all done.
Options If you want to have invisible users in the list, go to the plugin manager, click edit to edit this plugin then add this to the beginning:
HTML Code:
$showinvisible = 1;
Show Your Support
This modification may not be copied, reproduced or published elsewhere without author's permission.
I was able to get this working on v 3.7.4 BUT only if your using PHP 4.x I'm working on editing the array calls for PHP 5 and will update post if I ever suss it out.
But, It must be installed as a plugin. Do not import the xml file!
This also works on my v3.6.9 board as well.
As this is my first "real" contribution to vB.org, I hope that by attaching the instructions I created I'm breaking no rules nor offending the original author!
It is a minor change to the original installation.
Download the instructions attached and give it a go. I take no responsibility if it screws up your forums. I'm just attempting to be helpful. DO backup your database first please!
If anybody finds any fault with these instructions. Please feel free to edit and repost them.
An additional note....
If you use the optional line
<if condition="in_array($bbuserinfo['usergroupid'],array(5,6,7))">
to control you can use this Mod...
make sure the extra </if> statement following the phrase <!-- end currently active users -->
exisits when editing the SHOWTHREAD template. This </if> is included in the paste text of my instructions.
If you chose not to use this line, I do not believe it needs to be included.
Code:
<!-- end currently active users -->
</if>
And make sure there is also an </if> statement either before or after <!-- end who viewed this thread -->
Before saving and reloading the template.
Again last line should be as follows...
Code:
<!-- end who viewed this thread -->
</if>
I hope that makes sense to everyone. It's late and I've been at it for a while!