- Modificatie & Versie:Status mod
Directe link naar de modificatie: http://www.phpbbhacks.com/download/1617
Adres van je forum: http://www.moviereleases.nl
phpBB versie:2.0.22
Heb je onlangs een andere modificatie of stijl geïnstalleerd?Nee
Wat is het probleem?Alleen de topic starter kan de status aanpassen en de mods en admins moeten dit ook kunnen doen.
Code: Selecteer alles
##########################################################################################
##
## Hack Title: Add status to topic
## Hack Version: 1.0.3 (ex phpBB 2.0.5)
## optional Part: Only specific users may change the status 1.0
## Author: Acid
##
## Description: If only specific users should be able to change the status
## of a topic..
##
## Files to edit: 1
## viewtopic.php
##
##########################################################################################
##
## Installation/Author Notes:
## First always make a backup from the files/database that you're going to edit.
##
##########################################################################################
##
## Versions:
##
## 1.0 - added this optional part
##
##########################################################################################
######################### only staff may change the status ###########################
#
#-----[ OPEN ]--------------------------------------------------
#
# viewtopic.php
#
#-----[ FIND ]--------------------------------------------------
#
# if you added other optional parts the following might look different
if( $userdata['user_id'] != ANONYMOUS )
{
$template->assign_block_vars('switch_info', array());
}
#
#-----[ IN-LINE FIND ]--------------------------------------------------
#
$userdata['user_id'] != ANONYMOUS
#
#-----[ REPLACE WITH ]--------------------------------------------------
#
# ADMIN can be replaced with MOD or LESS_ADMIN
$userdata['user_level'] == ADMIN
#
#-----[ FIND ]--------------------------------------------------
#
if( isset($HTTP_POST_VARS['submit']) && $HTTP_POST_VARS['topic_info'] != 0 && $userdata['user_id'] != ANONYMOUS )
#
#-----[ IN-LINE FIND ]--------------------------------------------------
#
$userdata['user_id'] != ANONYMOUS
#
#-----[ REPLACE WITH ]--------------------------------------------------
#
# ADMIN can be replaced with MOD or LESS_ADMIN
$userdata['user_level'] == ADMIN
##################### only topic starters may change the status ######################
#
#-----[ OPEN ]--------------------------------------------------
#
# viewtopic.php
#
#-----[ FIND (just a quote) ]--------------------------------------------------
#
$sql = "SELECT t.topic_id, t.topic_title
#
#-----[ IN-LINE FIND ]--------------------------------------------------
#
t.topic_title
#
#-----[ AFTER ADD ]--------------------------------------------------
#
, t.topic_poster
#
#-----[ FIND ]--------------------------------------------------
#
$topic_title = $forum_topic_data['topic_title'];
#
#-----[ BELOW ADD ]--------------------------------------------------
#
$topic_poster = $forum_topic_data['topic_poster'];
#
#-----[ FIND ]--------------------------------------------------
#
# if you added other optional parts the following might look different
if( $userdata['user_id'] != ANONYMOUS )
{
$template->assign_block_vars('switch_info', array());
}
#
#-----[ IN-LINE FIND ]--------------------------------------------------
#
$userdata['user_id'] != ANONYMOUS
#
#-----[ AFTER ADD (before the last brace) ]--------------------------------------------------
#
&& $userdata['user_id'] == $topic_poster
#
#-----[ FIND ]--------------------------------------------------
#
if( isset($HTTP_POST_VARS['submit']) && $HTTP_POST_VARS['topic_info'] != 0 && $userdata['user_id'] != ANONYMOUS )
#
#-----[ IN-LINE FIND ]--------------------------------------------------
#
$userdata['user_id'] != ANONYMOUS
#
#-----[ AFTER ADD (before the last brace) ]--------------------------------------------------
#
&& $userdata['user_id'] == $topic_poster
##########################################################################################
##########################################################################################
##########################################################################################
Alvast bedankt,
Michel