Einzelnen Beitrag anzeigen
Alt 21.09.2007, 17:58   #11
Eddy
Veteran
 
Benutzerbild von Eddy
 
Registriert seit: 08.01.2000
Alter: 62
Beiträge: 375

Mein Computer

Standard

Wenn du dir den folgenden Code anschaust, siehst du, welche Dateien du ersetzen musst und wo du Code einfügen bzw. ändern musst. (Text verkürzt)

[code]
## Files To Edit: 5
## profile.php
## includes/constants.php
## includes/functions.php
## includes/usercp_register.php
## templates/subSilver/profile_add_body.tpl
##
## Included Files: 5
## admin/admin_captcha_config.php
## includes/usercp_confirm.php
## language/lang_english/lang_admin_captcha.php
## language/lang_german/lang_admin_captcha.php
## templates/subSilver/admin/admin_captcha_config.tpl
##
#-----[ PLEASE NOTE


#-----[ COPY FILES
#
# Copy / upload the following files to your phpBB root directory.
# The phpBB root directory is the directory on your server containing index.php
#

admin/admin_captcha_config.php to admin/admin_captcha_config.php
includes/usercp_confirm.php to includes/usercp_confirm.php
language/lang_english/lang_admin_captcha.php to language/lang_english/lang_admin_captcha.php
language/lang_german/lang_admin_captcha.php to language/lang_german/lang_admin_captcha.php
templates/subSilver/admin/admin_captcha_config.tpl to templates/subSilver/admin/admin_captcha_config.tpl
captcha/fonts/* to captcha/fonts/*

#
#----------[ SQL
#
# Run the following SQL statement to update your phpBB database.
# You can use phpMyAdmin or a similar tool to run this update.
#
# IMPORTANT: If you have changed the table prefix from the default of phpBB2,
# please be sure to replace phpbb with your prefix BEFORE running this update.
#

CREATE TABLE `phpbb_captcha_config` (
`config_name` varchar(255) NOT NULL default '',
`config_value` varchar(100) NOT NULL default '',
PRIMARY KEY (`config_name`)
) TYPE=MyISAM;

INSERT INTO `phpbb_captcha_config` VALUES ('width', '350');
INSERT INTO `phpbb_captcha_config` VALUES ('height', '90');
INSERT INTO `phpbb_captcha_config` VALUES ('exsample_code', 'SAMPLE');
INSERT INTO `phpbb_captcha_config` VALUES ('background_color', '#E5ECF9');
INSERT INTO `phpbb_captcha_config` VALUES ('jpeg', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('jpeg_quality', '50');
INSERT INTO `phpbb_captcha_config` VALUES ('pre_letters', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('pre_letters_great', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('font', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('trans_letters', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('chess', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('ellipses', '1');
INSERT INTO `phpbb_captcha_config` VALUES ('arcs', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('lines', '1');
INSERT INTO `phpbb_captcha_config` VALUES ('image', '0');
INSERT INTO `phpbb_captcha_config` VALUES ('bg_transition', '25');
INSERT INTO `phpbb_captcha_config` VALUES ('gammacorrect', '0.8');
INSERT INTO `phpbb_captcha_config` VALUES ('foreground_lattice_x', '15');
INSERT INTO `phpbb_captcha_config` VALUES ('foreground_lattice_y', '15');
INSERT INTO `phpbb_captcha_config` VALUES ('lattice_color', '#FFFFFF');
INSERT INTO `phpbb_captcha_config` VALUES ('avc_version', '1.2.0b');

ALTER TABLE `phpbb_confirm` CHANGE `code` `code` CHAR(10) NOT NULL;

#
#----------[ OPEN ]-------------------------------------
#

profile.php

#
#----------[ FIND ]-------------------------------------
#

else if ( $mode == 'confirm' )
{
// Visual Confirmation
if ( $userdata['session_logged_in'] )

#
#----------[ REPLACE WITH ]-----------------------------
#

else if ( $mode == 'confirm' )
{
// Visual Confirmation
if ( $userdata['session_logged_in'] && (htmlspecialchars($HTTP_GET_VARS['id']) != 'Admin'))

#
#----------[ OPEN ]-------------------------------------
#

includes/constants.php

#
#----------[ FIND ]-------------------------------------
#

define('CONFIG_TABLE', $table_prefix.'config');

#
#----------[ AFTER, ADD ]-------------------------------
#

define('CAPTCHA_CONFIG_TABLE', $table_prefix.'captcha_config');

#
#----------[ OPEN ]-------------------------------------
#

includes/functions.php

#
#----------[ FIND ]-------------------------------------
#

include($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin.' . $phpEx);

#
#----------[ AFTER, ADD ]-------------------------------
#

include($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_admin_captcha.' . $phpEx);

#
#----------[ OPEN ]-------------------------------------
#

includes/usercp_register.php

#
#----------[ FIND ]-------------------------------------
#

// Generate the required confirmation code
// NB 0 (zero) could get confused with O (the letter) so we make change it
$code = dss_rand();
$code = substr(str_replace('0', 'Z', strtoupper(base_convert($code, 16, 35))), 2, 6);

#
#----------[ REPLACE WITH ]-----------------------------
#

// Generate the required confirmation code
$code_length = mt_rand(4, 6);
$code = dss_rand();
$code = strtoupper(base_convert($code, 16, 35));
$code = str_replace('I', '', $code); // The letter I could get confused with the letter J and the number 1 (one) so we remove it
$code = str_replace('0', '', $code); // NB 0 (zero) could get confused with O (the letter) so we remove it
$code = substr($code, 2, $code_length);

#
#----------[ OPEN ]-------------------------------------
#

templates/subSilver/profile_add_body.tpl

#
#----------[ FIND ]-------------------------------------
#

<td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="6" maxlength="6" value="" /></td>

#
#----------[ REPLACE WITH ]-----------------------------
#

<td class="row2"><input type="text" class="post" style="width: 200px" name="confirm_code" size="10" maxlength="10" value="" /></td>

#
#-----[ SAVE/CLOSE ALL FILES
#
# EoM [code]
Eddy
____________________________________
Weniger ist mehr...
Eddy ist offline   Mit Zitat antworten