It's a nice hack but it would be nice if moderators couldn't alter these threads at all. Currently they can move/delete them still.
I fixed that on my board by adding the code to more sections of postings.php.
eg, at the top of a section under (for example)
PHP Code:
// ############################### start stick / unstick thread ###############################
you get an 'if' action thing. In this case
PHP Code:
if ($HTTP_POST_VARS['action'] == 'stick' OR ($action == 'stick' AND $s == $session['dbsessionhash'])) {
. Under this you get
PHP Code:
$threadid=verifyid("thread",$threadid);
$threadinfo=getthreadinfo($threadid);
if (!$threadinfo[visible]) {
$idname="thread";
eval("standarderror(\"".gettemplate("error_invalidid")."\");");
. Just put
PHP Code:
// +++++++ Super Close Thread Hack [ g-force2k2 ] +++++++
if(($threadinfo[open] == 2) AND ($bbuserinfo[usergroupid] != 6)) {
show_nopermission();
}
// +++++++ Super Close Thread Hack [ g-force2k2 ] +++++++
underneath any function you don't want moderators to have power for, such as deleting/moving a superclosed thread.
Also, in postings.php, it would be better if 'the thread has been successfully superopen/superclose'' read 'super-opened/super-closed or something. Just change
PHP Code:
$action = "superclose";
} elseif($threadinfo[open] == 2) {
$threadinfo[open] = 1;
$action = "superopen";
to
PHP Code:
$action = "super-closed";
} elseif($threadinfo[open] == 2) {
$threadinfo[open] = 1;
$action = "super-opened";