代碼: 選擇全部
#
# EasyMod 0.3.0 Compatible
##############################################################
## MOD Title: BotRegStop - Chinese
## MOD Author: kikir < kikir000@yahoo.com.tw > http://twspc.no-ip.info/forum/
## MOD Description: To stop Bot to Reg!
## MOD Version: 1.0.0
##
## Installation Level: Easy
## Installation Time: 5 Minutes
## Files To Edit: includes/usercp_register.php
## templates/subSilver/profile_add_body.tpl
## languages/{Chinese}/lang_main.php
## Included Files:
##
##
## License: http://opensource.org/licenses/gpl-license.php GNU General Public License v2
##############################################################
## Author Notes:
##
## 若您自己喜歡, 註冊中文碼可以自己設定
##
##############################################################
## MOD History:
## v1.0.0 非常基本的功能
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ OPEN ]------------------------------------------
#
includes/usercp_register.php
#
#-----[ FIND ]------------------------------------------
#
$strip_var_list = array('email' => 'email', 'icq' => 'icq', 'aim' => 'aim', 'msn' => 'msn', 'yim' => 'yim', 'website' => 'website', 'location' => 'location', 'occupation' => 'occupation', 'interests' => 'interests', 'confirm_code' => 'confirm_code');
#
#-----[ IN-LINE FIND ]------------------------------------------
#
$strip_var_list = array(
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
'regpass' => 'regpass',
#
#-----[ FIND ]------------------------------------------
#
$password_confirm = htmlspecialchars(stripslashes($password_confirm));
#
#-----[ AFTER, ADD ]------------------------------------------
#
$regpass = stripslashes($regpass);
#
#-----[ FIND ]------------------------------------------
#
if ( empty($username) || empty($new_password) || empty($password_confirm) || empty($email) )
#
#-----[ IN-LINE FIND ]------------------------------------------
#
empty($email)
#
#-----[ IN-LINE AFTER, ADD ]------------------------------------------
#
|| empty($regpass)
#
#-----[ FIND ]------------------------------------------
#
else if ( ( empty($new_password) && !empty($password_confirm) ) || ( !empty($new_password) && empty($password_confirm) ) )
{
$error = TRUE;
$error_msg .= ( ( isset($error_msg) ) ? '<br />' : '' ) . $lang['Password_mismatch'];
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
//BotRegStop
if ( $regpass != $lang['Regpass'] && $mode == 'register')
{
$error = TRUE;
$error_msg .= ( ( isset($error_msg) ) ? '<br />' : '' ) . $lang['Regpass_invalid'];
}
#
#-----[ FIND ]------------------------------------------
#
'L_PASSWORD_CONFIRM_IF_CHANGED' => ( $mode == 'editprofile' ) ? $lang['password_confirm_if_changed'] : '',
#
#-----[ AFTER, ADD ]------------------------------------------
#
'L_REGPASS' => $lang['L_Regpass'],
'REGPASS' => $lang['B_Regpass'].$lang['Regpass'],
#
#-----[ OPEN ]------------------------------------------
#
languages/{Chinese}/lang_main.php
#
#-----[ FIND ]------------------------------------------
#
//
// That's all Folks!
// -------------------------------------------------
?>
#
#-----[ BEFORE, ADD ]------------------------------------------
# ** $lang['Regpass'] 的設定值可以自行更改
// BotRegStop
$lang['RegPass_invalid'] = '您輸入的是錯誤的註冊通關碼!';
$lang['L_Regpass'] = '註冊通關碼';
$lang['B_Regpass'] = '請輸入這段通關碼: ';
$lang['Regpass'] = '人';
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/profile_add_body.tpl
#
#-----[ FIND ]------------------------------------------
#
<!-- BEGIN switch_confirm -->
#
#-----[ AFTER, ADD ]------------------------------------------
#
<tr>
<td class="row1"><span class="gen">{L_REGPASS}: * </span><br />
<span class="gensmall">{REGPASS}</span></td>
<td class="row2">
<input class="post" style="width: 200px" name="regpass" size="25" maxlength="32" value="" />
</td>
</tr>
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM