vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Selective Moderator Hiding (https://vborg.vbsupport.ru/showthread.php?t=66327)

coRtALoS 06-20-2004 03:07 AM

Selective Moderator Hiding
 
Looking for a hack that allows me to selectively hide moderators on the forum index. I realize you can hide users from the Forum Leaders page, however I can't find a hack that allows you to hide certain usergroups from showing up on the forum index or subforum pages.

I apologize if this is a redundant question, however I tried searching for such a beast repeatedly through the forums to no avail.

I'm currently running v2.3.4

---Edit---

I apologize for not posting in the right section. I've reported this to a moderator.

Xenon 06-20-2004 06:55 PM

*moved*

coRtALoS 07-05-2004 03:36 PM

I apologize for bumping, however this is still a problem I need resolved on my forums.

If there is already an answer to this problem somewhere else on the forums, please PM me a link to the thread.

Xenon 07-05-2004 04:42 PM

hmm, i can help you on the index part, which should be quite equivalent to the forumdisplay part:

open index.php and find:
PHP Code:

$forummoderators=$DB_site->query('SELECT user.userid,user.username,moderator.forumid
                                  FROM moderator
                                  LEFT JOIN user
                                    ON (moderator.userid=user.userid)
                                  ORDER BY user.username'
); 

and change it into:
PHP Code:

$forummoderators=$DB_site->query('SELECT user.userid,user.username,moderator.forumid
                                  FROM moderator
                                  LEFT JOIN user
                                    ON (moderator.userid=user.userid)
                                  WHERE user.usergroupid NOT IN (xx, yy, zz)
                                  ORDER BY user.username'
); 

and then just replace xx, yy, zz with the usergroupid's of the groups you don't want to show up in the listing :)

Boofo 07-05-2004 04:56 PM

Wouldn't it be better to use userid as the modertaors are probably all from the same usergroup?

Will this give an error with no SELECT for user.usergroupid?

Xenon 07-05-2004 05:30 PM

well, i just answered the question, he asked for usergroups which shouldn appear ;)

and nope, the condition field does not have to be in the result as well.

coRtALoS 07-08-2004 04:08 AM

My last problem is that user still shows up on the Forum Leaders page. Should I use the same bit of code for that page as well?

And thank you very much for that help Xenon.

It worked on the homepage, and I just had to edit the forumdisplay.php to get it to work when you're viewing the groups of general sections.

Then a quick editing of $moderatedby in the template got rid of the listed moderator when in the threadview section.

Thanks again... someone should make you... admin... :p

Xenon 07-08-2004 12:27 PM

*gg*

yeah, tell that Logician guy of vb.org that i should be an admin ^^

actually you should be able to to that on forumsleader page as well, as it's just an added condition


All times are GMT. The time now is 07:02 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.01830 seconds
  • Memory Usage 1,728KB
  • 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
  • (2)bbcode_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete