vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   Mini-Hack: Quick Reply does not show in Closed Thread even for Moderators (https://vborg.vbsupport.ru/showthread.php?t=59924)

Erwin 01-08-2004 10:00 PM

Mini-Hack: Quick Reply does not show in Closed Thread even for Moderators
 
Quick Reply does not show in Closed Thread even to Mods (Mini-Hack)

I found it annoying that even though staff close threads, the Quick Reply still shows up for staff because staff can always reply to closed threads. This caused staff to keep posting because some staff miss the fact that the thread is closed.

This is a mini-hack to make the Quick Reply not show up for everyone when a thread is closed. Staff can still reply by clicking on the "Closed" button.

A quick mod to showthread.php:

Find:

PHP Code:

($thread['open'] OR can_moderate($threadinfo['forumid'], 'canopenclose')) 

Change to:

PHP Code:

($thread['open']) 

Done! :)

Remember, when changing code WITHIN a query, don't add comments around the change. That would cause a parse error. ;)

corsacrazy 01-08-2004 11:01 PM

this certainly is a mini hack nice work mate shud come in handy

FleaBag 01-09-2004 02:20 PM

I second that, will definitely come in handy.

poetic 01-09-2004 05:44 PM

Very nice.. I did this with an if statement, but you way makes much more sense.

Hoffi 01-09-2004 11:19 PM

This Hack could win be the smallest-Hack award. :D

But the use is much bigger. Thanks.

Sebastian 03-01-2004 10:28 PM

you can do this without hacking.

in showthread template find:

Code:

$quickreply
replace with:

Code:

<if condition="$thread['open']">$quickreply</if>

Ig@r 03-02-2004 04:16 AM

Quote:

I found it annoying that even though staff close threads, the Quick Reply still shows up
Me too. :)

Thanks for the hack.

Sebastian, I would like to thank you as well. Template modification is easier :)

NexVision 03-02-2004 06:17 AM

anyway to make it show for admins and mods

Erwin 03-02-2004 09:10 AM

Quote:

Originally Posted by Sebastian
you can do this without hacking.

in showthread template find:

Code:

$quickreply
replace with:

Code:

<if condition="$thread['open']">$quickreply</if>

True - but believe it or not, I prefer file hacking now to template hacking because I find it easier to compare files when upgrading than to revert templates and remodify them. :)

Beermonster 03-02-2004 05:52 PM

nice :) thanks

FleaBag 03-04-2004 04:21 PM

Just got around to adding this, thanks Erwin.

sabret00the 04-01-2004 09:04 AM

Quote:

Originally Posted by FleaBag
Just got around to adding this, thanks Erwin.

is there anyway that you can make sure it remains for admins?

Choclo 04-18-2004 11:15 AM

Installed, thanks!

BeatYou 06-19-2004 05:49 AM

I had the same problem, but not that my mods didn't know the thread was closed, they were just cocky and post anyway. Thanks

Borgs8472 09-30-2004 10:11 PM

Blessed art thou

Mitsuaki 10-06-2004 07:35 PM

Quote:

Originally Posted by sabret00the
is there anyway that you can make sure it remains for admins?

I figured a way to do it using the template mod.... still working on the file mod for it

In showthread template find:

Code:

$quickreply
Replace with:

Code:

<if condition="$thread['open']">$quickreply
<else />
<if condition="$bbuserinfo[usergroupid]== '6'">$quickreply</if>
</if>

'6' is the usergroup ID for Admins... Yours may be different lol

Caiman 12-04-2004 01:12 AM

Works a treat, thanks!

yoyoyoyo 01-13-2005 02:40 AM

Quote:

Originally Posted by Mitsuaki
I figured a way to do it using the template mod.... still working on the file mod for it

In showthread template find:

Code:

$quickreply
Replace with:

Code:

<if condition="$thread['open']">$quickreply
<else />
<if condition="$bbuserinfo[usergroupid]== '6'">$quickreply</if>
</if>

'6' is the usergroup ID for Admins... Yours may be different lol


*****clicks update******

Reece D 03-01-2005 09:59 AM

*installed* cheers for this ..

Eagle Creek 03-02-2005 08:11 PM

Does it work on 3.0.7?

Oblivion Knight 03-02-2005 08:16 PM

Quote:

Originally Posted by Eagle Creek
Does it work on 3.0.7?

Yes, it continues to work perfectly on 3.0.7.. :)

Eagle Creek 03-02-2005 08:18 PM

Quote:

Originally Posted by Oblivion Knight
Yes, it continues to work perfectly on 3.0.7.. :)

Th.. th... THANKYOU :D

Polo 03-16-2005 02:23 PM

Right now this may not be a problem for our Christian Site, but once our site grows i'm pretty sure it will come handy ;) Thanks Erwin.


All times are GMT. The time now is 04:45 PM.

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.01165 seconds
  • Memory Usage 1,762KB
  • 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
  • (8)bbcode_code_printable
  • (2)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (23)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