Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)

Reply
 
Thread Tools Display Modes
  #1  
Old 08-29-2003, 08:10 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Hide Admin Thread Options

I don't know if this is done before, but i would find it very usefull if the 'Admin Thread Options dropdown' would be visible for only Admins, Super Moderators & moderators. Btw i am running 2.2.7 and it shows the dropdown for regular members and guests...

Best regards!
Attached Images
File Type: gif admin_thread_options.gif (7.4 KB, 0 views)
Reply With Quote
  #2  
Old 08-29-2003, 08:19 AM
assassingod's Avatar
assassingod assassingod is offline
 
Join Date: Jul 2002
Posts: 3,337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Try this, open up showthread.php and find:
PHP Code:
if (ismoderator($thread['forumid']) or $getperms['canopenclose'] or $getperms['candeletethread'] or $getperms['canmove']) {
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";");
} else {
  
$adminoptions " ";

replace with

PHP Code:
if (ismoderator($thread['forumid']) or $getperms['canopenclose'] or $getperms['candeletethread'] or $getperms['canmove']) {
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";");
} elseif (
$bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == 6) {
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";");
} else {
  
$adminoptions " ";

Reply With Quote
  #3  
Old 08-29-2003, 08:28 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm thanks!, i tried but it's still there!

Well, it did work for guests though, but registered users can still see it. What could it be?
Reply With Quote
  #4  
Old 08-29-2003, 08:31 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here are my settings with the forumpermissions for registered users. Hope it's usefull....
Attached Images
File Type: gif registered.gif (10.5 KB, 0 views)
Reply With Quote
  #5  
Old 08-29-2003, 08:33 AM
assassingod's Avatar
assassingod assassingod is offline
 
Join Date: Jul 2002
Posts: 3,337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You could try:
PHP Code:
if (ismoderator($thread['forumid']) or $getperms['canopenclose'] or $getperms['candeletethread'] or $getperms['canmove']) { 
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";"); 
} elseif (
$bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == ) { 
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";"); 
} else { 
  
$adminoptions " "

Reply With Quote
  #6  
Old 08-29-2003, 08:36 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

LOL, now it's visible for both Registered & Guests.
Sorry the other one worked better
Reply With Quote
  #7  
Old 08-29-2003, 08:39 AM
assassingod's Avatar
assassingod assassingod is offline
 
Join Date: Jul 2002
Posts: 3,337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Whoops, I forgot to change something, use:
PHP Code:
if (ismoderator($thread['forumid']) or $getperms['canopenclose'] or $getperms['candeletethread'] or $getperms['canmove']) { 
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";"); 
} elseif (
$bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == OR $bbuserinfo[usergroupid] == ) { 
  
$adminoptions " "
} else { 
  
$adminoptions " "

Reply With Quote
  #8  
Old 08-29-2003, 08:43 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm, it's the same result as the first one
Registered can still see the Admin Thread Options, but guests can't see it. We are very close! Almost working! (trying to motivate you)
Reply With Quote
  #9  
Old 08-29-2003, 08:45 AM
assassingod's Avatar
assassingod assassingod is offline
 
Join Date: Jul 2002
Posts: 3,337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hehe, try this:
Find:
PHP Code:
if (ismoderator($thread['forumid']) or $getperms['canopenclose'] or $getperms['candeletethread'] or $getperms['canmove']) {
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";");
} else {
  
$adminoptions " ";

Under that, add:

PHP Code:
if ($bbuserinfo[usergroupid] == or $bbuserinfo[usergroupid] == 5) {
  eval(
"\$adminoptions = \"".gettemplate("showthread_adminoptions")."\";");
} else {
  
$adminoptions " ";

Reply With Quote
  #10  
Old 08-29-2003, 08:51 AM
Aaron1's Avatar
Aaron1 Aaron1 is offline
 
Join Date: Oct 2002
Location: Amsterdam
Posts: 200
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You rock! That worked!

Thanks alot!

Ok let's continue with my next request!

Combining Multiquote & The quickreply hack:
https://vborg.vbsupport.ru/showthrea...threadid=56588

Nah just kidding you helped me enough for today already
Appreciated!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:05 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03406 seconds
  • Memory Usage 2,295KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (6)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (2)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete