[分享]ChatBox_mod 中文化(第三版)

MODs Released by Other phpbb Sites
非官方認證通過之 MOD ,或許有安全性之疑慮,所有問題由原發表者回覆!

版主: 版主管理群

主題已鎖定
william91
竹貓忠實會員
竹貓忠實會員
文章: 642
註冊時間: 2003-04-16 20:53
來自: 牛牛農場
聯繫:

[分享]ChatBox_mod 中文化(第三版)

文章 william91 »

這是小弟弟第一次做的中文化....如做得不好....請見諒^^

還加上一個自己寫的少少MOD^^

中文化第三版可於以下網址下載:

ChatBox_mod 中文化第三版下載

代碼: 選擇全部

##############################################################\r
## 外掛名稱: ChatBox 中文版
## 外掛作者: Smartor < smartor_xp@hotmail.com > (Hoang Ngoc Tu) http://smartor.is-root.com
## 外掛中文化: William Leung <william91@hkbn.net> http://ppbc.hk.st
## 外掛描述: 這個外掛會在你的 phpBB2 加上即時聊天室
##	     只有已註冊的使用者可使用聊天室, 
##	     系統管理員能夠使用一些命令操控聊天室(/KICK username, /CLEAR). 表情符號開關.
##	     只在 phpBB 2.0.x/MySQL 執行過測試
## 外掛版本: 1.1.9g
##
## 此外掛的安裝難度: 容易
## 安裝須時: 10 分鐘
## 要修改的檔案: 3
##	index.php
##	templates/subSilver/index_body.tpl
##	language/lang_chinese_traditional_taiwan/lang_main.php
##
## 要增加的檔案: 10
##	chatbox_db_install.php	(此檔案只是需要執行SQL)
##	chatbox_front.php
##	chatbox_mod/chatbox.css
##	chatbox_mod/chatbox.php
##	chatbox_mod/chatbox_config.php
##	chatbox_mod/chatbox_drop.php
##	chatbox_mod/chatbox_function.php
##	chatbox_mod/messenger_list.php
##	chatbox_mod/messenger_send.php
##	chatbox_mod/messenger_view.php
##############################################################
## 這個外掛是由 GPL 發佈
## Intellectual Property is retained by the MOD Author(s) listed above
##############################################################
## Author Notes:
##
##############################################################
## 在安裝前, 必須備份所有檔案
##############################################################

#
#-----[ 開啟 ]---------------------------------------------
#
index.php

#
#-----[ 尋找 ]---------------------------------------------
#
	$template->assign_vars(array(
		'TOTAL_POSTS' => sprintf($l_total_post_s, $total_posts),
		'TOTAL_USERS' => sprintf($l_total_user_s, $total_users),
		'NEWEST_USER' => sprintf($lang['Newest_user'], '<a href="' . append_sid("profile.$phpEx?

mode=viewprofile&" . POST_USERS_URL . "=$newest_uid") . '">', $newest_user, '</a>'),

#
#-----[ 在之前,加入 ]--------------------------------------
#
	// ChatBox Mod
	require_once($phpbb_root_path . 'chatbox_front.php');

#
#-----[ 尋找 ]---------------------------------------------
#
		'L_MARK_FORUMS_READ' => $lang['Mark_all_forums'],

#
#-----[ 在之後, 加入 ]--------------------------------------
#
		// ChatBox Mod
		'TOTAL_CHATTERS_ONLINE' => sprintf($lang['How_Many_Chatters'], $howmanychat),
		'CHATTERS_LIST' => sprintf($lang['Who_Are_Chatting' ], $chatters),
		'L_CLICK_TO_JOIN_CHAT' => $lang['Click_to_join_chat'],
		'S_JOIN_CHAT' => append_sid("chatbox_mod/chatbox.$phpEx"),
		'CHATBOX_NAME' => $userdata['user_id'] . '_ChatBox', // To make easier to test on my PC
		'L_LOGIN_TO_JOIN_CHAT' => $lang['Login_to_join_chat'],

#
#-----[ 開啟 ]---------------------------------------------
#
language/lang_chinese_traditional_taiwan/lang_main.php

#
#-----[ 尋找 ]---------------------------------------------
#
//
// That's all Folks!

#
#-----[ 在之前, 加入 ]--------------------------------------
#
// ChatBox Mod
$lang['How_Many_Chatters'] = '現時有 <B>%d</B> 位使用者在聊天室內';
$lang['Who_Are_Chatting' ] = '<B>%s</B>';
$lang['Click_to_join_chat'] = '按一下加入聊天室';
$lang['ChatBox'] = 'ChatBox';
$lang['log_out_chat'] = '你已成功離開聊天室';
$lang['Send'] = '發送';
$lang['Login_to_join_chat'] = '登入加入聊天';


#
#-----[ 開啟 ]--------------------------------------------
#
templates/subSilver/index_body.tpl

#
#-----[ 尋找 ]--------------------------------------------
#
<td class="row1" align="center" valign="middle" rowspan="2"><img src="templates/subSilver/images/whosonline.gif" 

alt="{L_WHO_IS_ONLINE}" /></td>

#
#-----[ 取代為 ]------------------------------------
#
<td class="row1" align="center" valign="middle" rowspan="3"><img src="templates/subSilver/images/whosonline.gif" 

alt="{L_WHO_IS_ONLINE}" /></td>

#
#-----[ 尋找 ]---------------------------------------------
#
  <tr>
	<td class="row1" align="left"><span class="gensmall">{TOTAL_USERS_ONLINE}   [ {L_WHOSONLINE_ADMIN} ]   [ 

{L_WHOSONLINE_MOD} ]<br />{RECORD_USERS}<br />{LOGGED_IN_USER_LIST}</span></td>
  </tr>

#
#-----[ 在之後, 加入 ]--------------------------------------
#
  <tr>
	<td class="row1" align="left"><span class="gensmall">{TOTAL_CHATTERS_ONLINE}   
	<!-- BEGIN switch_user_logged_out -->
	[ {L_LOGIN_TO_JOIN_CHAT} ]
	<!-- END switch_user_logged_out -->
	<!-- BEGIN switch_user_logged_in -->
	[ <a href="javascript:void(0);" onClick="window.open

('{S_JOIN_CHAT}','{CHATBOX_NAME}','scrollbars=no,width=540,height=450')">{L_CLICK_TO_JOIN_CHAT}</a> ]
	<!-- END switch_user_logged_in -->
	<br />{CHATTERS_LIST}
	</span>
	</td>
  </tr>

#
#-----[ 複製 ]--------------------------------------------
#
複製 chatbox_front.php 和 chatbox_front.php 到你的PHPBB目錄
複製 chatbox_mod/*.* 到 chatbox_mod/

#
#-----[ 執行SQL語法 ]---------------------------------------------
# 請執行以下的SQL語法, 也可以執行 chatbox_db_install.php 運行這些語法
# 在執行後必須移除此檔案
#
CREATE TABLE phpbb_chatbox (
	id int(11) NOT NULL auto_increment,
	name varchar(99) NOT NULL,
	msg varchar(255) NOT NULL,
	timestamp int(10) unsigned NOT NULL,
	PRIMARY KEY (id));

CREATE TABLE phpbb_chatbox_session (
	username varchar(99) NOT NULL,
	lastactive int(10) DEFAULT '0' NOT NULL,
	laststatus varchar(8) NOT NULL,
	UNIQUE username (username));

#
#-----[ 儲存/關閉所有檔案 ]------------------------------------------
#
# EoM

將聊天室連結加到Overall_header:

代碼: 選擇全部

#################################################################
## 外掛名稱:	將聊天室連結加到Overall_header 中文版
## 外掛作者:	Smartor <smartor_xp@hotmail.com> - http://smartor.is-root.com
## 外掛中文化: William Leung <william91@hkbn.net> http://ppbc.hk.st
##
## 此外掛的安裝難度: 容易
## 安裝須時: 2 分鐘
##
## 要修改的檔案: 2
##	includes/page_header.php
##	templates/subSilver/overall_header.tpl
##
## 要增加的檔案: 0
##
#################################################################
## Author Notes:
##
#################################################################

#
#-----[ 開啟 ]--------------------------------------------------
#
templates/subSilver/overall_header.tpl

#
#-----[ 尋找 ]----------------------------------------
#
<a href="{U_SEARCH}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_search.gif" width="12" height="13" border="0" alt="{L_SEARCH}" hspace="3" />{L_SEARCH}</a>

#
#-----[ 在之後, 加入 ]---------------------------------
#
   <a href="javascript:void(0);" onClick="window.open

('{S_JOIN_CHAT}','{CHATBOX_NAME}','scrollbars=no,width=540,height=450')" class="mainmenu"><img 

src="templates/subSilver/images/icon_mini_login.gif" width="12" height="13" border="0" hspace="3" />聊天室</a></span> 

#
#-----[ 開啟 ]--------------------------------------------------
#
includes/page_header.php

#
#-----[ 尋找 ]----------------------------------------
#
$template->assign_vars(array(

#
#-----[ 在之後, 加入 ]----------------------------------
#
	'S_JOIN_CHAT' => append_sid("chatbox_mod/chatbox.$phpEx"),
	'CHATBOX_NAME' => $userdata['user_id'] . '_ChatBox',

#
#-----[ 儲存/關閉所有檔案 ]---------------------------------
#
如果你想更改你聊天室的標題

代碼: 選擇全部

#################################################################
## 外掛名稱: 更改聊天室標題
## 外掛作者: William Leung <william91@hkbn.net> http://ppbc.hk.st
##
## 此外掛的安裝難度: 非常容易
## 安裝須時: 1-2 分鐘
##
## 要修改的檔案: 2
##	chatbox_mod/chatbox.php
##	language/lang_chinese_traditional_taiwan/lang_main.php
##
## 要增加的檔案: 0
##
#################################################################
## Author Notes:
##
#################################################################

#
#-----[ 開啟 ]--------------------------------------------------
#
chatbox_mod/chatbox.php

#
#-----[ 尋找 ]----------------------------------------
#
<title><?php echo $nick . " - " . $lang['ChatBox'] . " " . _CHATBOX_VERSION; ?></title>

#
#-----[ 取代]----------------------------------------
#
<title><?php echo $nick . " - " . $lang['Chat_name'] . " "  ; ?></title>

#
#-----[ 開啟 ]--------------------------------------------------
#
language/lang_chinese_traditional_taiwan/lang_main.php

#
#-----[ 尋找 ]----------------------------------------
#
// ChatBox Mod
$lang['How_Many_Chatters'] = '現時有 <B>%d</B> 位使用者在聊天室內';
$lang['Who_Are_Chatting' ] = '<B>%s</B>';
$lang['Click_to_join_chat'] = '按一下加入聊天室';
$lang['ChatBox'] = 'ChatBox';
$lang['log_out_chat'] = '你已成功離開聊天室';
$lang['Send'] = '發送';
$lang['Login_to_join_chat'] = '登入加入聊天';

#
#-----[ 取代]----------------------------------------
#

// ChatBox Mod
$lang['How_Many_Chatters'] = '現時有 <B>%d</B> 位使用者在聊天室內';
$lang['Who_Are_Chatting' ] = '<B>%s</B>';
$lang['Click_to_join_chat'] = '按一下加入聊天室';
$lang['ChatBox'] = 'ChatBox';
$lang['log_out_chat'] = '你已成功離開聊天室';
$lang['Send'] = '發送';
$lang['Login_to_join_chat'] = '登入加入聊天';
$lang['Chat_name'] = 'XXXXXX';


註:'XXXXXX'內的請你換上自己聊天室的名字

#
#-----[ 儲存/關閉所有檔案 ]---------------------------------
#
這就完成^^

有任何問題可以在"外掛問題"區找我, 我一定會以最快的時間解答你的問題!

william91共修改了9次, 最後修改時間:24/7/2003 18:49
間中上來走走吧~
主題已鎖定

回到「非官方認證外掛」