的分區設定, 請問我哪裡改錯了呢? 謝謝!!

版主: 版主管理群

########################################################
## Mod Title: Global Announcment mod
## Mod Version: 1.2.6
## Author: Niels Chr. Denmark < ncr@db9.dk > (Niels Chr. R鷣) HTTP://mods.db9.dk
##
## This mod is for phpBB2!! ver 2.0.3
##
## This mod, makes it posible to post global announcements vieweble in all forums,
## it suppport auth level, witch means you can define in forum permissions,
## who have right to post global announcements, note though that if you have given
## this rights in one forum, then it gives no meaning to restrict it to the same user(s)
## in another forum - the post is global
## Note also that once a global announcement is posted, the permission on the topic, will be the same as that
## forum where it is initially posted, this is useful if you wan to restrict your users from replying - solution is
## to post the global announcement inside a forum where the users can not reply, the subject of the global
## announcement will though always be visible, even though the user have no rigths , it is first when they try to view
## the topic, that the permission in the original forum takes over
##
## There is a known isue this this mod, a global announcement will still "belong" to the forum where
## it original was posted, this means that if a user reply to sutch a post, then they will be redirected
## to that forum, nothing to do about that, also when using search, it will be displayed "as" in the original posted forum
##
## If you wish to assign special rigths to the global announcement, then ypou may cosumice the conatants.php , change the
## value of HIDDEN_CAT witch a category id,. This category is hidden to all except ADMIN
## inside this category, make a forum with a empty name, and post the global announcement here
## that way preventing the users to se the forum, where the global announcement is posted
## make this forum "view_auth" ALL and "read_auth" ALL, all other settings are up to you
##
## (in current version of phpbb2, you can't create a forum without a name, but you can delete the name after it is created ! )
##
## instalation rated medium
## instalation time: aprox 10-20 min
##
## Files to edit: 14
## language/lang_english/lang_main.php
## language/lang_english/lang_admin.php
## viewforum.php
## index.php
## includes/constants.php
## search.php
## posting.php
## modcp.php
## includes/auth.php
## includes/functions.php
## admin/admin_forumauth.php
## Admin/admin_ug_auth.php
## templates/subSilver/viewforum_body.tpl
## templates/subSilver/template.cfg
## Files to add: 2
## templates/subSilver/images/folder_global_announce.gif
## templates/subSilver/images/folder_global_announce_new.gif
##
## History:
## 0.9.0. - initial beta
## 1.0.0. - initial release
## 1.0.5. - History started, fixed a error in admin_ug_auth.php
## 1.0.6. - one more typo fixed in the admin_ug_auth.php
## 1.0.7. - makes it posible to make a hidden category, so global announcement can be controlled more exact
## 1.2.0. - now confirmed on phpBB2 ver 2.0.2, minor changes needed
## 1.2.1. - folder URL of folder_global_announce_new.gif was wrong
## 1.2.2. - fixed that the "hidden" cattegory "global_announcement" was showen in drop-down box
## 1.2.3. - includes images for "fi apple" template
## 1.2.4. - improved the code into search.php thanks to the user "FX"
## 1.2.5. - verifyed for 2.0.6. and EM ready
##
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/downloads/ 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/downloads/
##############################################################
## Authors Notes:
##
## if you are using a prefix to you DB tabels then you have to add this to
## the SQL commands, e.g. "phpbb_users" instead of just "users" - ONLY
## in the initial [SQL ADD] commands, not in the php code !
## if in doubt about how to do this, then run the included db_update.php, witch will do the nessesary changes
##
## The most important thing to keep in mind is, take your time, make
## sure you are finding the correct lines to modify, then take care to paste the new code.
## Please also keep in mind, if you are using more than one language file or theme at your
## site, you will need to edit the corrosponding files for each occurrence. Good Luck!
##
#################################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
## and the Database
#################################################################
#
#-----[ SQL ]------------------------------------------
#
ALTER TABLE forums ADD auth_globalannounce TINYINT (2) DEFAULT '3' NOT NULL AFTER auth_announce
ALTER TABLE auth_access ADD auth_globalannounce TINYINT (1) AFTER auth_announce
#
#-----[ OPEN ]------------------------------------------
#
# (remember to change this in every language dir)
language/lang_english/lang_main.php
#
#-----[ FIND ]------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
// add to global announcment mod
$lang['Topic_global_announcement']='<b>Global Announcement:</b>';
$lang['Post_global_announcement'] = 'Global Announcement';
#
#-----[ OPEN ]------------------------------------------
#
language/lang_english/lang_admin.php
#
#-----[ FIND ]------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
// add to global announcment mod
$lang['Globalannounce'] ='Global Announce';
#
#-----[ OPEN ]------------------------------------------
#
index.php
#
#-----[ FIND ]------------------------------------------
#
FROM " . CATEGORIES_TABLE . " c
#
#-----[ AFTER, ADD ]------------------------------------------
#
".(($userdata['user_level']!=ADMIN)? "WHERE c.cat_id<>'".HIDDEN_CAT."'" :"" )."
#
#-----[ OPEN ]------------------------------------------
#
viewforum.php
#
#-----[ FIND ]------------------------------------------
#
//
// All announcement data, this keeps announcements
// on each viewforum page ...
#
#-----[ BEFORE, ADD ]------------------------------------------
#
//
// All GLOBAL announcement data, this keeps GLOBAL announcements
// on each viewforum page ...
//
$sql = "SELECT t.*, u.username, u.user_id, u2.username as user2, u2.user_id as id2, p.post_time, p.post_username
FROM " . TOPICS_TABLE . " t, " . USERS_TABLE . " u, " . POSTS_TABLE . " p, " . USERS_TABLE . " u2
WHERE t.topic_poster = u.user_id
AND p.post_id = t.topic_last_post_id
AND p.poster_id = u2.user_id
AND t.topic_type = " . POST_GLOBAL_ANNOUNCE . "
ORDER BY t.topic_last_post_id DESC ";
if( !$result = $db->sql_query($sql) )
{
message_die(GENERAL_ERROR, "Couldn't obtain topic information", "", __LINE__, __FILE__, $sql);
}
$topic_rowset = array();
$total_announcements = 0;
while( $row = $db->sql_fetchrow($result) )
{
$topic_rowset[] = $row;
$total_announcements++;
}
$db->sql_freeresult($result);
#
#-----[ FIND ]------------------------------------------
#
$topic_rowset = array();
$total_announcements = 0;
#
#-----[ REPLACE WITH ]------------------------------------------
#
//$topic_rowset = array();
//$total_announcements = 0;
#
#-----[ FIND ]------------------------------------------
#
AND t.topic_type <> " . POST_ANNOUNCE . "
#
#-----[ AFTER, ADD ]------------------------------------------ \r
#
AND t.topic_type <> " . POST_GLOBAL_ANNOUNCE . "
#
#-----[ FIND ]------------------------------------------
#
'FOLDER_ANNOUNCE_NEW_IMG' => $images['folder_announce_new'],
#
#-----[ AFTER, ADD ]------------------------------------------
#
'FOLDER_GLOBAL_ANNOUNCE_IMG' => $images['folder_global_announce'],
'FOLDER_GLOBAL_ANNOUNCE_NEW_IMG' => $images['folder_global_announce_new'],
#
#-----[ FIND ]------------------------------------------
#
'L_ANNOUNCEMENT' => $lang['Post_Announcement'],
#
#-----[ AFTER, ADD ]------------------------------------------
#
'L_GLOBAL_ANNOUNCEMENT' => $lang['Post_global_announcement'],
#
#-----[ FIND ]------------------------------------------
#
if( $topic_type == POST_ANNOUNCE )
{
$topic_type = $lang['Topic_Announcement'] . ' ';
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
else if( $topic_type == POST_GLOBAL_ANNOUNCE )
{
$topic_type = $lang['Topic_global_announcement'] . ' ';
}
#
#-----[ FIND ]------------------------------------------
#
if( $topic_rowset[$i]['topic_type'] == POST_ANNOUNCE )
{
$folder = $images['folder_announce'];
#
#-----[ BEFORE, ADD ]------------------------------------------
#
if( $topic_rowset[$i]['topic_type'] == POST_GLOBAL_ANNOUNCE )
{
$folder = $images['folder_global_announce'];
$folder_new = $images['folder_global_announce_new'];
}
else
#
#-----[ OPEN ]------------------------------------------
#
includes/constants.php
#
#-----[ FIND ]------------------------------------------
#
define('AUTH_ATTACH', 11);
#
#-----[ AFTER, ADD ]------------------------------------------
#
define('AUTH_GLOBALANNOUNCE', 12);
define('HIDDEN_CAT', 0); // NOTE: change this value to the forum id, of the forum, witch you would like to be hidden
#
#-----[ OPEN ]------------------------------------------
#
includes/auth.php
#
#-----[ FIND ]------------------------------------------
#
case AUTH_ALL:
$a_sql = '
#
#-----[ IN-LINE FIND ]------------------------------------------
#
';
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, a.auth_globalannounce
#
#-----[ FIND ]------------------------------------------
#
$auth_fields = array(
#
#-----[ IN-LINE FIND ]------------------------------------------
#
);
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, 'auth_globalannounce'
#
#-----[ FIND ]------------------------------------------
#
default:
break;
#
#-----[ BEFORE, ADD ]------------------------------------------
#
case AUTH_GLOBALANNOUNCE:
$a_sql = 'a.auth_globalannounce';
$auth_fields = array('auth_globalannounce');
break;
#
#-----[ OPEN ]------------------------------------------
#
includes/functions.php
#
#-----[ FIND ]------------------------------------------
#
function make_jumpbox
{
global
#
#-----[ IN-LINE FIND ]------------------------------------------
#
;
#
#-----[ IN-LINE BEFORE ADD ]------------------------------------------
#
, $userdata
#
#-----[ FIND ]------------------------------------------
#
$sql = "SELECT
FROM " . CATEGORIES_TABLE . " c, " . FORUMS_TABLE . " f
WHERE f.cat_id = c.cat_id
#
#-----[ AFTER, ADD ]------------------------------------------
#
".(($userdata['user_level'] == ADMIN)? "" : "AND c.cat_id<>'".HIDDEN_CAT."'" )."
#
#-----[ OPEN ]------------------------------------------
#
search.php
#
#-----[ FIND ]------------------------------------------
#
if ($topic_type == POST_ANNOUNCE)
{
$topic_type =
}
#
#-----[ BEFORE, ADD ]------------------------------------------
#
if($topic_type == POST_GLOBAL_ANNOUNCE )
{
$topic_type = $lang['Topic_global_announcement'] . " ";
} else
#
#-----[ FIND ]------------------------------------------
#
else if ( $searchset[$i]['topic_type'] == POST_ANNOUNCE )
#
#-----[ BEFORE, ADD ]------------------------------------------
#
else if ( $searchset[$i]['topic_type'] == POST_GLOBAL_ANNOUNCE )
{
$folder = $images['folder_global_announce'];
$folder_new = $images['folder_global_announce_new'];
}
#
#-----[ FIND ]------------------------------------------
#
$sql = "SELECT c.cat_title, c.cat_id, f.forum_name, f.forum_id
FROM " . CATEGORIES_TABLE . " c, " . FORUMS_TABLE . " f
WHERE f.cat_id = c.cat_id
#
#-----[ AFTER, ADD ]------------------------------------------
#
".(($userdata['user_level'] == ADMIN)? "" : "AND c.cat_id<>'".HIDDEN_CAT."'" )."
#
#-----[ OPEN ]------------------------------------------
#
posting.php
#
#-----[ FIND ]------------------------------------------
#
if ( $topic_type == POST_ANNOUNCE )
#
#-----[ BEFORE, ADD ]------------------------------------------
#
if ( $topic_type == POST_GLOBAL_ANNOUNCE )
{
$is_auth_type = 'auth_globalannounce';
}
else
#
#-----[ FIND ]------------------------------------------
#
$topic_type = ( $topic_type != $post_data['topic_type'] && !$is_auth['auth_sticky'] && !$is_auth['auth_announce'] ) ? $post_data['topic_type'] : $topic_type;
#
#-----[ IN-LINE FIND ]------------------------------------------
#
)
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
&& !$is_auth['auth_globalannounce']
#
#-----[ FIND ]------------------------------------------
#
$topic_type_toggle .= ' /> ' . $lang['Post_Announcement'] . ' ';
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
if( $is_auth['auth_globalannounce'] )
{
$topic_type_toggle .= '<input type="radio" name="topictype" value="' . POST_GLOBAL_ANNOUNCE . '"';
if ( $post_data['topic_type'] == POST_GLOBAL_ANNOUNCE )
{
$topic_type_toggle .= ' checked="checked"';
}
$topic_type_toggle .= ' /> ' . $lang['Post_global_announcement'] . ' ';
}
#
#-----[ OPEN ]------------------------------------------
#
modcp.php
#
#-----[ FIND ]------------------------------------------
#
if ( $row['topic_type'] == POST_ANNOUNCE )
#
#-----[ BEFORE, ADD ]------------------------------------------
#
if ( $row['topic_type'] == POST_GLOBAL_ANNOUNCE )
{
$folder_img = $images['folder_global_announce'];
$folder_alt = $lang['Global_announcement'];
}else
#
#-----[ FIND ]------------------------------------------
#
if ( $topic_type == POST_ANNOUNCE )
#
#-----[ BEFORE, ADD ]------------------------------------------
#
if ( $topic_type == POST_GLOBAL_ANNOUNCE )
{
$topic_type = $lang['Topic_global_announcement'] . ' ';
}else
#
#-----[ OPEN ]------------------------------------------
#
admin/admin_forumauth.php
#
#-----[ FIND ]------------------------------------------
#
// View Read Post Reply Edit Delete Sticky Announce Vote Poll
#
#-----[ AFTER, ADD ]------------------------------------------
#
// Globalannounce added
#
#-----[ FIND ]------------------------------------------------
#
$simple_auth_ary = array(
0 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
1 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
2 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
3 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
4 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
5 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------------
#
6 => array(
#
#-----[ IN-LINE FIND ]----------------------------------------
#
),
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, AUTH_MOD
#
#-----[ FIND ]------------------------------------------
#
$forum_auth_fields = array(
#
#-----[ IN-LINE FIND ]------------------------------------------
#
);
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, 'auth_globalannounce'
#
#-----[ FIND ]----------------------------------------
#
']);
#
#-----[ IN-LINE FIND ]----------------------------------------
#
);
#
#-----[ IN-LINE REPLACE WITH ]--------------------------------
#
,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'auth_globalannounce' => $lang['Globalannounce']);
#
#-----[ OPEN ]------------------------------------------
#
admin/admin_ug_auth.php
#
#-----[ FIND ]------------------------------------------
#
$forum_auth_fields = array(
#
#-----[ IN-LINE FIND ]------------------------------------------
#
);
#
#-----[ IN-LINE BEFORE, ADD ]---------------------------------
#
, 'auth_globalannounce'
#
#-----[ FIND ]------------------------------------------
#
'auth_announce' => AUTH_ANNOUNCE,
#
#-----[ FIND ]----------------------------------------
#
);
#
#-----[ IN-LINE FIND ]----------------------------------------
#
);
#
#-----[ IN-LINE REPLACE WITH ]--------------------------------
#
,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'auth_globalannounce' => AUTH_GLOBALANNOUNCE);
#
#-----[ FIND ]----------------------------------------
#
']);
#
#-----[ IN-LINE FIND ]----------------------------------------
#
);
#
#-----[ IN-LINE REPLACE WITH ]--------------------------------
#
,
#
#-----[ AFTER, ADD ]------------------------------------------
#
'auth_globalannounce' => $lang['Globalannounce']);
#
#-----[ FIND ]------------------------------------------
#
SET auth_view = 0,
WHERE
#
#-----[ IN-LINE FIND ]------------------------------------------
#
WHERE
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, auth_globalannounce = 0
#
#-----[ FIND ]------------------------------------------
#
SET auth_view = 0,
WHERE
#
#-----[ IN-LINE FIND ]------------------------------------------
#
WHERE
#
#-----[ IN-LINE BEFORE, ADD ]------------------------------------------
#
, auth_globalannounce = 0
#
#-----[ OPEN ]------------------------------------------
#
# (remember to do this to alle templates instaled on the board)
templates/subSilver/viewforum_body.tpl
#
#-----[ FIND ]------------------------------------------
#
<td width="20" align="center"><img src="{FOLDER_ANNOUNCE_IMG}" alt="{L_ANNOUNCEMENT}" width="19" height="18" /></td>
<td class="gensmall">{L_ANNOUNCEMENT}</td>
#
#-----[ REPLACE WITH ]------------------------------------------
#
<td width="20" align="center"><img src="{FOLDER_GLOBAL_ANNOUNCE_IMG}" alt="{L_GLOBAL_ANNOUNCEMENT}" width="19" height="18" /></td>
<td class="gensmall">{L_GLOBAL_ANNOUNCEMENT}</td>
#
#-----[ FIND ]------------------------------------------
#
<td width="20" align="center"><img src="{FOLDER_STICKY_IMG}" alt="{L_STICKY}" width="19" height="18" /></td>
<td class="gensmall">{L_STICKY}</td>
#
#-----[ REPLACE WITH ]------------------------------------------
#
<td width="20" align="center"><img src="{FOLDER_ANNOUNCE_IMG}" alt="{L_ANNOUNCEMENT}" width="19" height="18" /></td>
<td class="gensmall">{L_ANNOUNCEMENT}</td>
#
#-----[ FIND ]------------------------------------------
#
<td class="gensmall"><img src="{FOLDER_LOCKED_IMG}"
<td class="gensmall">{L_NO_NEW_POSTS_LOCKED}</td>
#
#-----[ AFTER, ADD ]------------------------------------------
#
<td> </td>
<td width="20" align="center"><img src="{FOLDER_STICKY_IMG}" alt="{L_STICKY}" width="19" height="18" /></td>
<td class="gensmall">{L_STICKY}</td>
#
#-----[ OPEN ]------------------------------------------
#
# (remeber to do this to alle templates instaled on the board)
templates/subSilver/subSilver.cfg
#
#-----[ FIND ]------------------------------------------
#
$images['folder_announce_new'] = "$current_template_images/folder_announce_new.gif";
#
#-----[ AFTER, ADD ]------------------------------------------
#
$images['folder_global_announce'] = "$current_template_images/folder_global_announce.gif";
$images['folder_global_announce_new'] = "$current_template_images/folder_global_announce_new.gif";
#
#-----[ COPY ]------------------------------------------
#
copy root/templates/subSilver/images/folder_global_announce.gif to templates/subSilver/images/
copy root/templates/subSilver/images/folder_global_announce_new.gif to templates/subSilver/images/
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
##############################################################
## MOD Title: Split topic type
## MOD Author: Ptirhiik < admin@rpgnet-fr.com > (Pierre) http://rpgnet.clanmckeen.com
## MOD Description:
## This mod splits the topic per type in the viewform display
##
## MOD Version: 2.0.0
##
## Installation Level: Easy
## Installation Time: 10 Minutes
## Files To Edit:
## viewforum.php
## includes/page_header.php
## language/lang_english/lang_admin.php
## language/lang_english/lang_main.php
## templates/subSilver/viewforum_body.tpl
##
## templates/subSilver/subSilver.cfg
##
## Included Files:
## mod_split_topic_type.php
## mod-mods_settings/admin_board_extend.php
## mod-mods_settings/functions_mods_settings.php
## mod-mods_settings/board_config_extend_body.tpl
##
## mod-topics_list/functions_topics_list.php
## mod-topics_list/topics_list_box.tpl
##
## mod-topics_list/graph.gif/folder_announce_own.gif
## mod-topics_list/graph.gif/folder_announce_new_own.gif
## mod-topics_list/graph.gif/folder_own.gif
## mod-topics_list/graph.gif/folder_new_own.gif
## mod-topics_list/graph.gif/folder_hot_own.gif
## mod-topics_list/graph.gif/folder_new_hot_own.gif
## mod-topics_list/graph.gif/folder_lock_own.gif
## mod-topics_list/graph.gif/folder_lock_new_own.gif
## mod-topics_list/graph.gif/folder_sticky_own.gif
## mod-topics_list/graph.gif/folder_sticky_new_own.gif
##############################################################
## 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:
## o users can choose their prefered setup (required full mods settings mod to be installed).
## Admin can also choose to override the users choice for each setup parameter.
##
##############################################################
## MOD History:
##
## 2003-09-09 - Version 2.0.0
## - use of the functions_topics_list
## - use the mods_settings for user preferences
##
## 2003-07-13 - Version 1.0.5
## - allow to split the topic in boxes
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ SQL ]-------------------------------------------------
#
#
# This part is optional : do it only if you want your users to be able to choose their setup
# if you want so, you'll have to install the MOD-mods_settings mod included in the pack
#
# note also you haven't to add the user_split_global_announce if you don't use global announces mod
#
ALTER TABLE phpbb_users ADD user_split_global_announce TINYINT(1) DEFAULT '1' NOT NULL;
ALTER TABLE phpbb_users ADD user_split_announce TINYINT(1) DEFAULT '1' NOT NULL;
ALTER TABLE phpbb_users ADD user_split_sticky TINYINT(1) DEFAULT '1' NOT NULL;
ALTER TABLE phpbb_users ADD user_split_topic_split TINYINT(1) DEFAULT '0' NOT NULL;
#
#-----[ COPY ]------------------------------------------------
#
# those ones are a part of the MOD-mods_settings mod, and are required for split topic type v 2.0.0
#
copy mod_split_topic_type.php to includes/mods_settings/mod_split_topic_type.php
copy mod-mods_settings/functions_mods_settings.php to includes/functions_mods_settings.php
copy mod-mods_settings/admin_board_extend.php to admin/admin_board_extend.php
copy mod-mods_settings/board_config_extend_body.tpl to templates/subSilver/admin/board_config_extend_body.tpl
#
#-----[ COPY ]------------------------------------------------
#
# this part is relative to the topics list mod
#
copy mod-topics_list/functions_topics_list.php to includes/functions_topics_list.php
copy mod-topics_list/topics_list_box.tpl to templates/subSilver/topics_list_box.tpl
copy mod-topics_list/graph.gif/folder_announce_own.gif to templates/subSilver/images/folder_announce_own.gif
copy mod-topics_list/graph.gif/folder_announce_new_own.gif to templates/subSilver/images/folder_announce_new_own.gif
copy mod-topics_list/graph.gif/folder_own.gif to templates/subSilver/images/folder_own.gif
copy mod-topics_list/graph.gif/folder_new_own.gif to templates/subSilver/images/folder_new_own.gif
copy mod-topics_list/graph.gif/folder_hot_own.gif to templates/subSilver/images/folder_hot_own.gif
copy mod-topics_list/graph.gif/folder_new_hot_own.gif to templates/subSilver/images/folder_new_hot_own.gif
copy mod-topics_list/graph.gif/folder_lock_own.gif to templates/subSilver/images/folder_lock_own.gif
copy mod-topics_list/graph.gif/folder_lock_new_own.gif to templates/subSilver/images/folder_lock_new_own.gif
copy mod-topics_list/graph.gif/folder_sticky_own.gif to templates/subSilver/images/folder_sticky_own.gif
copy mod-topics_list/graph.gif/folder_sticky_new_own.gif to templates/subSilver/images/folder_sticky_new_own.gif
#
#-----[ OPEN ]------------------------------------------------
#
viewforum.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
include($phpbb_root_path . 'common.'.$phpEx);
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
//-- add
include_once($phpbb_root_path . 'includes/functions_topics_list.'. $phpEx);
//-- fin mod : split topic type --------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
//
// Okay, lets dump out the page ...
//
#
#-----[ AFTER, ADD ]------------------------------------------
#
#************************************************************************************
# NOTE :
# ------
# /!\ Important : I strongly recommand to mute all the lines between the nexts
# --------- /* and */
# by adding // in front of each lines or by deleting all.
#
# ie: // if( $total_topics )
#
#************************************************************************************
//-- mod : split topic type ------------------------------------------------------------------------
//-- add
// adjust the item id
for ($i=0; $i < count($topic_rowset); $i++)
{
$topic_rowset[$i]['topic_id'] = POST_TOPIC_URL . $topic_rowset[$i]['topic_id'];
}
// set the bottom sort option
$footer = $lang['Display_topics'] . ': ' . $select_topic_days . ' ' . ( !empty($s_display_order) ? $s_display_order : '') . '<input type="submit" class="liteoption" value="' . $lang['Go'] . '" name="submit" />';
// send the list
$allow_split_type = true;
$display_nav_tree = false;
topic_list('TOPICS_LIST_BOX', 'topics_list_box', $topic_rowset, '', $allow_split_type, $display_nav_tree, $footer);
//-- delete
/*
//---------------------------------------
//
// Note : all the code that was standing there stands now in functions_topics_list.php, topic_list() func
//
//---------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
$topics_count -= $total_announcements;
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
*/
//-- fin mod : split topic type --------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
}
else
{
//
// No topics
//
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
//-- delete
/*
#
#-----[ FIND ]------------------------------------------------
#
//
// Parse the page and print
//
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
*/
//-- fin mod : split topic type --------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
includes/page_header.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
$template->pparse('overall_header');
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
//-- add
include_once($phpbb_root_path . 'includes/mods_settings/mod_split_topic_type.' . $phpEx);
//-- fin mod : split topic type --------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
language/lang_english/lang_admin.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : mods settings ---------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : mods settings ---------------------------------------------------------------------------
//-- add
$lang['Configuration_extend'] = 'Configuration +';
$lang['Override_user_choices'] = 'Override user choices';
//-- end of mod : mods settings --------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
language/lang_english/lang_main.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : split topic type ------------------------------------------------------------------------
//-- add
$lang['Announce_settings'] = 'Announcements';
$lang['split_global_announce'] = 'Split global announcement';
$lang['split_announce'] = 'Split announcement';
$lang['split_sticky'] = 'Split sticky';
$lang['split_topic_split'] = 'Seperate topic types in different boxes';
//-- fin mod : split topic type --------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/subSilver.cfg
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : topics list -----------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : topics list -----------------------------------------------------------------------------
//-- add
$images['folder_global_announce'] = "$current_template_images/folder_announce.gif";
$images['folder_global_announce_new'] = "$current_template_images/folder_announce_new.gif";
$images['folder_global_announce_own'] = "$current_template_images/folder_announce_own.gif";
$images['folder_global_announce_new_own'] = "$current_template_images/folder_announce_new_own.gif";
$images['folder_own'] = "$current_template_images/folder_own.gif";
$images['folder_new_own'] = "$current_template_images/folder_new_own.gif";
$images['folder_hot_own'] = "$current_template_images/folder_hot_own.gif";
$images['folder_hot_new_own'] = "$current_template_images/folder_new_hot_own.gif";
$images['folder_locked_own'] = "$current_template_images/folder_lock_own.gif";
$images['folder_locked_new_own'] = "$current_template_images/folder_lock_new_own.gif";
$images['folder_sticky_own'] = "$current_template_images/folder_sticky_own.gif";
$images['folder_sticky_new_own'] = "$current_template_images/folder_sticky_new_own.gif";
$images['folder_announce_own'] = "$current_template_images/folder_announce_own.gif";
$images['folder_announce_new_own'] = "$current_template_images/folder_announce_new_own.gif";
//-- fin mod : topics list -------------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/viewforum_body.tpl
#
#-----[ FIND ]------------------------------------------------
#
<form method="post" action="{S_POST_DAYS_ACTION}">
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
<!-- mod : split topic type -->
#
#-----[ FIND ]------------------------------------------------
#
#
#************************************************************************************
# NOTE :
# ------
# The lines deleted here are reported in topics_list_box.tpl. You will probably
# want to customize topics_list_box.tpl the same way viewforum_body.tpl was if
# you use a particular template with other classes than the ones used by subSilver.
#
#************************************************************************************
<table
<tr>
<th
<th
<th
<th
<th
</tr>
<!-- BEGIN topicrow -->
<tr>
<td
<td
{topicrow.GOTO_PAGE}</span></td>
<td
<td
<td
<td
</tr>
<!-- END topicrow -->
<!-- BEGIN switch_no_topics -->
<tr>
<td
</tr>
<!-- END switch_no_topics -->
<tr>
<td class="catBottom"
<input type="submit" class="liteoption" value="{L_GO}" name="submit" />
</span></td>
</tr>
</table>
#
#-----[ REPLACE WITH ]----------------------------------------
#
{TOPICS_LIST_BOX}
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------------
#
# EoM
會。lasthero 寫:請問伊夢兒, 裝完全域公告後, 控制台裡面會有全域公告的相關設定嗎? (例如全域公告的開關之類的)
你控制台內「全域公告分區」、「公告分區」和「置頂分區」都切至「是」了嗎??lasthero 寫:雖說在貼文章的時候仍有全域公告的選項可選, 但張貼後, 卻只被分為普通公告, 而且文章標題前面原本應該有"全域公告:"也沒了
我不是指說公告置頂設定裡面喔, 我是指其他的地方是否有全域公告的設定可調?依夢兒 寫: 會。
我是先裝公告置頂分區之後再裝全域公告的。
裝了全域公告之後,控制台就多了全域公告分區的選項。
我的公告置頂分區設定在控制台裡面並沒有"全域公告分區"這項設定, 只有公告分依夢兒 寫: 你控制台內「全域公告分區」、「公告分區」和「置頂分區」都切至「是」了嗎??
不然你改裝舊版的好了....我目前是用 1.0.5 版,因為沒啥時間懶得更新。
反正 2.0 版只是多了一個讓 USER 自行選擇的功能,我覺得還是統一設定比較好,不要開放給 USER 設定,也就沒更新了。
1.0.5 已經用 E-MAIL 寄給你了,請收信,裝裝看是否正常??
全域公告是要在文章裡面設定的啦....lasthero 寫:我不是指說公告置頂設定裡面喔, 我是指其他的地方是否有全域公告的設定可調?
有可能是你漏裝了,不然就是有些地方該加 // 或是有些地方該拿掉 // 而你沒有這麼作。lasthero 寫:我的公告置頂分區設定在控制台裡面並沒有"全域公告分區"這項設定, 只有公告分
區以及置頂分區而已......><
看過了,看不出來問題是出在哪裡....lasthero 寫:請伊夢兒幫我看一下新版設定檔, 我先暫時不換上1.0.5版的, 如果說真的沒辦法的話, 我再換上去試試看........
這是正常的啦!! 1.0.5 版就是這麼清爽,只要改原來 phpBB 的幾個檔案就好了。lasthero 寫:對了, 我收到您的信了, 不過裡面似乎只有一些說明檔(.txt), 並無其他附屬檔案(.php)?