vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Show Thread Enhancements - Who viewed this thread? (https://vborg.vbsupport.ru/showthread.php?t=61222)

Carter876 03-31-2004 06:48 AM

Quote:

Originally Posted by Carter876
Hi Gery W, I like very much this hack but I have a questions:
Is there the possibility that onlyAdmins see this "Who viewed this thread" Panel (if Yes, How?)

Tnx and compliments for the nice hack :)

Regards

Gery can you answer to my question, pls?

Tnx :)

Ocean 03-31-2004 09:56 AM

Quote:

Originally Posted by Carter876
Gery can you answer to my question, pls?

Tnx :)

Carter876, take the entire block of code that you are supposed to enter into the Showthread Template and surround it like this:

Code:


<if condition="is_member_of($bbuserinfo,6)">
 
<!-- Inserted code goes here -->
 
</if>
 




By doing that, you are saying that that code will apply only if the User is a member of Group-ID 6 (which should be the default for Admins).



VitroX 03-31-2004 12:21 PM

This is a wonderfull hack, thanks for making.

I wonder if it is possible to show the members with color depending of the usergroup where they belongs, per example Admins in red, Mods in blue, etc.

Thanks again.

Carter876 03-31-2004 08:40 PM

Quote:

Originally Posted by Ocean
Carter876, take the entire block of code that you are supposed to enter into the Showthread Template and surround it like this:

Code:


<if condition="is_member_of($bbuserinfo,6)">
 
<!-- Inserted code goes here -->
 
</if>
 




By doing that, you are saying that that code will apply only if the User is a member of Group-ID 6 (which should be the default for Admins).



Tnx for the help but this code don't work (i have a Parse error) :disappointed:

Someone can help me, pls?

Regards

Ocean 04-01-2004 07:32 PM

Quote:

Originally Posted by Gary W
All 3 are fixed :) The invisible users part, it shows invisible users to all users to have less strain on the servers.

Hi, Gary! I finally got the chance to install the revised version. And although the problem with the Invisible Users and the Title Bar are fixed (thanks!), the third problem remains. Clicking on a Username still opens up the Profile in a new window, rather than the same one.


p.s. I'm still interested in knowing what I would need to change, if I wanted Invisible Users handled the same way it is on the Forum Home. (i.e. Only shown to those with access to see Invisible Users, suffixed with the "*" character, etc...) :) :) :)

Ocean 04-01-2004 07:37 PM

Quote:

Originally Posted by Carter876
Tnx for the help but this code don't work (i have a Parse error) :disappointed:

Someone can help me, pls?

Regards

Carter876, the code does the job perfectly. I just tried it myself. Are you sure you implemented it correctly?

The code needs to be inserted into the ShowThread **Template** (NOT Showthread.php). If you put it into ShowThread.php, that would account for the Parse Error.

But in the Template, the complete code to be inserted (including the Admin-Only section) is as follows:


Code:


 
<if condition="is_member_of($bbuserinfo,6)">

<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"><tbody>
<tr>
<td class="thead">
<a style="float:$stylevar[right]" href="#top" onClick="return toggle_collapse('forumhome_todayactiveusers')"><img id="collapseimg_forumhome_todayactiveusers" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_todayactiveusers].gif" alt="" border="0" /></a>
$vbphrase[already_viewed_this_thread]
</td>
</tr>
</tbody>
<tbody id="collapseobj_forumhome_todayactiveusers" style="$vbcollapse[collapseobj_forumhome_todayactiveusers]">
<tr>
<td class="alt1"><div class="smallfont">
$thread[viewers]
                </div></td>
</tr>
</tbody>
</table>
<br />

</if>

Also, remember that although I stated that Group-ID 6 should be the default for Admins - that doesn't mean that it's not possible for that to have changed on your system. It's worth double checking both that, as well as the syntax.

Gary King 04-01-2004 08:37 PM

Quote:

Originally Posted by Ocean
Hi, Gary! I finally got the chance to install the revised version. And although the problem with the Invisible Users and the Title Bar are fixed (thanks!), the third problem remains. Clicking on a Username still opens up the Profile in a new window, rather than the same one.


p.s. I'm still interested in knowing what I would need to change, if I wanted Invisible Users handled the same way it is on the Forum Home. (i.e. Only shown to those with access to see Invisible Users, suffixed with the "*" character, etc...) :) :) :)

To open in same window, remove target="_blank"

Carter876 04-01-2004 09:04 PM

Quote:

Originally Posted by Ocean
Carter876, the code does the job perfectly. I just tried it myself. Are you sure you implemented it correctly?

The code needs to be inserted into the ShowThread **Template** (NOT Showthread.php). If you put it into ShowThread.php, that would account for the Parse Error.

Ops you are right ;) , it now works perfectly :up: Tnx :D

I have another question (maybe a little bug) and a suggestion:

1.) If I close the collapsable table of "Who viewed this thread" I see my Collapsable table of "Number of Active Users" in Index that is Closed too, why!?
2.) Is there the possibility to signal how many times a user has seen that threads?

Tnx for the help! :)

Regards

Isotope 04-02-2004 12:04 AM

What needs to be changed in the code, if I want this bar to be Collapsed by default, rather than expanded?

pcalloway 04-03-2004 11:07 PM

My table heading is showing as blank rather then stating:

"Already viewed this thread:"

In the phrase manager I used "already_viewed_this_thread" as the Var name and "Already viewed this thread:" as the text. Did I goof something up?


All times are GMT. The time now is 07:08 AM.

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.01158 seconds
  • Memory Usage 1,750KB
  • 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
  • (3)bbcode_code_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)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