代碼: 選擇全部
##############################################################
## MOD Title: Simply Merge Threads
## MOD Author: Ptirhiik < admin@rpgnet-fr.com > (Pierre) http://www.rpgnet-fr.com
## MOD Description:
## This mod allows to merge two topics
## MOD Version: 1.0.1
##
## Installation Level: Easy
## Installation Time: 10 Minutes
## Files To Edit:
## viewtopic.php
## includes/functions.php
## templates/subSilver/subSilver.cfg
##
## Included Files:
## lang_extend_merge.php
## merge.php
## merge_body.tpl
## merge_select_body.tpl
## topic_merge.gif
##
## --- lang settings ---
## mod-lang_settings/lang_extend_mac.php
##
## --- topics list ---
## 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 To be able to edit your languages installed on the board, please install the administration
## language management tool included in the mod-lang_settings directory : MOD-lang_settings.txt
##
##############################################################
## MOD History:
##
## 2003-10-21 - Version 1.0.1
## - add the use of the lang settings
## - add the use of the topics list
## - fix the loose of poll while merging a poll to a topic without a poll
##
## 2003-07-27 - Version 1.0.0
## - first release
##
## 2003-07-12 - Version 0.0.1
## - first beta
##
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ COPY ]------------------------------------------------
#
copy lang_extend_merge.php to language/lang_english/lang_extend_merge.php
copy merge.php to merge.php
copy merge_body.tpl to templates/subSilver/merge_body.tpl
copy merge_select_body.tpl to templates/subSilver/merge_select_body.tpl
copy topic_merge.gif to templates/subSilver/images/topic_merge.gif
\n#
#-----[ COPY ]------------------------------------------------
#
# this part is relative to the lang_settings mod
#
copy mod-lang_settings/lang_extend_mac.php to includes/lang_extend_mac.php
#
#-----[ 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 ]------------------------------------------------
#
viewtopic.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : merge -----------------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
$topic_mod .= "<a href="modcp.$phpEx?" . POST_TOPIC_URL . "=$topic_id&mode=split&sid=" . $userdata['session_id'] . '"><img src="' . $images['topic_mod_split'] . '" alt="' . $lang['Split_topic'] . '" title="' . $lang['Split_topic'] . '" border="0" /></a> ';
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : merge -----------------------------------------------------------------------------------
//-- add
$topic_mod .= '<a href="' . append_sid("merge.$phpEx?" . POST_TOPIC_URL . '=' . $topic_id) . '"><img src="' . $images['topic_mod_merge'] . '" alt="' . $lang['Merge_topics'] . '" title="' . $lang['Merge_topics'] . '" border="0" /></a> ';
//-- fin mod : merge -------------------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
includes/functions.php
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
# This part can already be existing : if so, just skip it
#
//-- mod : language settings -----------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
//
// Set up style
//
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
# This part can already be existing : if so, just skip it
#
//-- mod : language settings -----------------------------------------------------------------------
//-- add
include($phpbb_root_path . './includes/lang_extend_mac.' . $phpEx);
//-- fin mod : language settings -------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
}
if ( empty($template) )
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
# This part can already be existing : if so, just skip it
#
//-- mod : language settings -----------------------------------------------------------------------
//-- add
include($phpbb_root_path . './includes/lang_extend_mac.' . $phpEx);
//-- fin mod : language settings -------------------------------------------------------------------
#
#-----[ OPEN ]------------------------------------------------
#
templates/subSilver/subSilver.cfg
#
#-----[ FIND ]------------------------------------------------
#
<?php
#
#-----[ AFTER, ADD ]------------------------------------------
#
//-- mod : topics list -----------------------------------------------------------------------------
//-- mod : merge -----------------------------------------------------------------------------------
#
#-----[ FIND ]------------------------------------------------
#
?>
#
#-----[ BEFORE, ADD ]-----------------------------------------
#
//-- mod : merge -----------------------------------------------------------------------------------
//-- add
$images['topic_mod_merge'] = "$current_template_images/topic_merge.gif";
//-- fin mod : merge -------------------------------------------------------------------------------
//-- 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 -------------------------------------------------------------------------
#
#-----[ SAVE/CLOSE ALL FILES ]--------------------------------
#
# EoM