Administracií?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?³n del Foro

Index

Código: Seleccionar todo
##############################################################
## MOD Title: Colorize Forumtitle
## MOD Author: OXPUS (Karsten Ude) http://www.oxpus.de
## MOD Description: Gives admins the possibility to enter a color seperatly for each forumtitle.
## MOD Version: 1.0.0
##
## Installation Level: Easy
## Installation Time: 3-5 Minutes
## Files To Edit: 7
## index.php
## admin/admin_forums.php
## language/lang_english/lang_admin.php
## language/lang_german/lang_admin.php
## templates/subSilver/index_body.tpl
## templates/subSilver/admin/forum_admin_body.tpl
## templates/subSilver/admin/forum_edit_body.tpl
##
## Included Files: n/a
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes:
##
## Instead entering the given SQL-Statement, you can upload the file db_update.php
## to your phpbb root directory and run this with your browser.
## This file will do all nessassary changes in the database for you.
## After using this file, please delete it to avoid errors.
##
## If you have installed the Categories Hierarchy Mod, ONLY install the add-on!
##
##############################################################
## MOD History:
##
## 2004-05-12 - Version 1.0.0
## - First release
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ SQL ]------------------------------------------
#
ALTER TABLE phpbb_forums ADD COLUMN forum_color varchar(6) DEFAULT '' NOT NULL;
#
#-----[ OPEN ]------------------------------------------
#
index.php
#
#-----[ FIND ]------------------------------------------
#
'FORUM_NAME' => $forum_data[$j]['forum_name'],
#
#-----[ AFTER, ADD ]------------------------------------------
#
'FORUM_COLOR' => ( $forum_data[$j]['forum_color'] != '' ) ? 'style="color: #'.$forum_data[$j]['forum_color'].'"' : '',
#
#-----[ OPEN ]------------------------------------------
#
admin/admin_forums.php
#
#-----[ FIND ]------------------------------------------
#
$forumdesc = $row['forum_desc'];
$forumstatus = $row['forum_status'];
#
#-----[ AFTER, ADD ]------------------------------------------
#
$forum_color = $row['forum_color'];
#
#-----[ FIND ]------------------------------------------
#
$forumdesc = '';
#
#-----[ AFTER, ADD ]------------------------------------------
#
$forum_color = '';
#
#-----[ FIND ]------------------------------------------
#
$forumstatus == ( FORUM_LOCKED ) ? $forumlocked = "selected=\"selected\"" : $forumunlocked = "selected=\"selected\"";
#
#-----[ AFTER, ADD ]------------------------------------------
#
$forum_color = ( empty($forum_color) ) ? '' : $forum_color;
#
#-----[ FIND ]------------------------------------------
#
'L_FORUM_TITLE' => $l_title,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'L_FORUM_COLOR' => $lang['Forum_color'],
'L_FORUM_COLOR_EXPLAIN' => $lang['Forum_color_explain'],
#
#-----[ FIND ]------------------------------------------
#
'FORUM_NAME' => $forumname,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'FORUM_COLOR' => $forum_color,
#
#-----[ FIND ]------------------------------------------
#
$sql = "INSERT INTO " . FORUMS_TABLE . " (forum_id, forum_name, cat_id, forum_desc, forum_order, forum_status, prune_enable" . $field_sql . ")
VALUES ('" . $next_id . "', '" . str_replace("\'", "''", $HTTP_POST_VARS['forumname']) . "', " . intval($HTTP_POST_VARS[POST_CAT_URL]) . ", '" . str_replace("\'", "''", $HTTP_POST_VARS['forumdesc']) . "', $next_order, " . intval($HTTP_POST_VARS['forumstatus']) . ", " . intval($HTTP_POST_VARS['prune_enable']) . $value_sql . ")";
#
#-----[ IN-LINE FIND ]------------------------------------------
#
, forum_name
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
, forum_color
#
#-----[ IN-LINE FIND ]------------------------------------------
#
'" . str_replace("\'", "''", $HTTP_POST_VARS['forumname']) . "'
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
, '" . str_replace("\'", "''", $HTTP_POST_VARS['forum_color']) . "'
#
#-----[ FIND ]------------------------------------------
#
$sql = "UPDATE " . FORUMS_TABLE . "
SET forum_name = '" . str_replace("\'", "''", $HTTP_POST_VARS['forumname']) . "', cat_id = " . intval($HTTP_POST_VARS[POST_CAT_URL]) . ", forum_desc = '" . str_replace("\'", "''", $HTTP_POST_VARS['forumdesc']) . "', forum_status = " . intval($HTTP_POST_VARS['forumstatus']) . ", prune_enable = " . intval($HTTP_POST_VARS['prune_enable']) . "
WHERE forum_id = " . intval($HTTP_POST_VARS[POST_FORUM_URL]);
#
#-----[ IN-LINE FIND ]------------------------------------------
#
forum_name = '" . str_replace("\'", "''", $HTTP_POST_VARS['forumname']) . "'
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
, forum_color = '" . str_replace("\'", "''", $HTTP_POST_VARS['forum_color']) . "'
#
#-----[ FIND ]------------------------------------------
#
'FORUM_NAME' => $forum_rows[$j]['forum_name'],
#
#-----[ AFTER, ADD ]------------------------------------------
#
'FORUM_COLOR' => ( $forum_rows[$j]['forum_color'] != '' ) ? 'style="color: #'.$forum_rows[$j]['forum_color'].'"' : '',
#
#-----[ OPEN ]------------------------------------------
#
language/lang_english/lang_admin.php
#
#-----[ FIND ]------------------------------------------
#
$lang['Forum_edit_delete_explain'] = 'The form below will allow you to customize all the general board options. For User and Forum configurations use the related links on the left hand side';
#
#-----[ AFTER, ADD ]------------------------------------------
#
$lang['Forum_color'] = 'Set a color for the forum title';
$lang['Forum_color_explain'] = 'Leave this field blank to use the default color. Just enter the color number without leading \'#\'!';
#
#-----[ OPEN ]------------------------------------------
#
language/lang_german/lang_admin.php
#
#-----[ FIND ]------------------------------------------
#
$lang['Forum_edit_delete_explain'] = 'Hier kannst du alle allgemeinen Boardeinstellungen anpassen. Zur Benutzer- und Forenkonfiguration benutze bitte die entsprechenden Links auf der linken Seite';
#
#-----[ AFTER, ADD ]------------------------------------------
#
$lang['Forum_color'] = 'Trage eine Farbe fí?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?¼r den Forentitel ein.';
$lang['Forum_color_explain'] = 'Lass das Feld frei, um die Standardfarbe zu verwenden. Gib nur die Farbzahl ohne fí?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?Â?í?¼hrende \'#\' ein!';
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/index_body.tpl
#
#-----[ FIND ]------------------------------------------
#
{catrow.forumrow.FORUM_NAME}
#
#-----[ REPLACE WITH ]------------------------------------------
#
{catrow.forumrow.FORUM_NAME}
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/admin/forum_admin_body.tpl
#
#-----[ FIND ]------------------------------------------
#
{catrow.forumrow.FORUM_NAME}
{catrow.forumrow.FORUM_DESC}
#
#-----[ REPLACE WITH ]------------------------------------------
#
{catrow.forumrow.FORUM_NAME}
{catrow.forumrow.FORUM_DESC}
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/admin/forum_edit_body.tpl
#
#-----[ FIND ]------------------------------------------
#
{L_FORUM_STATUS}
{S_STATUS_LIST}
#
#-----[ AFTER, ADD ]------------------------------------------
#
{L_FORUM_COLOR}
{L_FORUM_COLOR_EXPLAIN}
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM