Zuerst mal Danke...
Nach dem ich dein Doc. studiert hab, hab ich mir mal die includes/constants.php angeguckt... Dort ist auch nix von ner iv_user_data...
Auch in keiner Modifikation steht dass man so etwas hinzufügen müssen...
Auch in einer db_update.php steht davon nix:
Code: Alles auswählen
<?php
/**
*
* @package phpBB3
* @file $Id: db_update.php, v 0.5.1
* @copyright (c) 2008 phpBB Gaming
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
* @ignore
*/
define('IN_PHPBB', true);
$phpbb_root_path = './';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);
// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup('common');
if ($user->data['user_type'] != USER_FOUNDER)
{
trigger_error('MUST_BE_FOUNDER');
}
//Set the config
set_config('points_enable', '1');
set_config('points_name', 'Points');
set_config('points_topic', '20');
set_config('points_post', '10');
$message = '<p style="color: green;">Config values have been set.</p><br />';
//Add the permissions
include($phpbb_root_path . 'includes/acp/auth.' . $phpEx);
$auth_admin = new auth_admin();
$permissions = array(
'global' => array(),
'local' => array('f_points'),
);
$auth_admin->acl_add_option($permissions);
$message .= '<p style="color: green;">Permissions have been entered.</p><br />';
// Add default permissions for Roles
$role_data = array(
'ROLE_ADMIN_FULL' => array('f_points'),
'ROLE_MOD_FULL' => array('f_points'),
'ROLE_MOD_STANDARD' => array('f_points'),
'ROLE_MOD_QUEUE' => array('f_points'),
'ROLE_MOD_SIMPLE' => array('f_points'),
'ROLE_USER_FULL' => array('f_points'),
'ROLE_USER_STANDARD' => array('f_points'),
'ROLE_USER_LIMITED' => array('f_points'),
'ROLE_USER_NOPM' => array('f_points'),
'ROLE_USER_NOAVATAR' => array('f_points'),
);
foreach ($role_data as $role => $options)
{
$sql = 'SELECT role_id FROM ' . ACL_ROLES_TABLE . " WHERE role_name = '{$role}'";
$db->sql_query($sql);
$role_id = $db->sql_fetchfield('role_id');
if ($role_id)
{
$sql = 'SELECT auth_option_id FROM ' . ACL_OPTIONS_TABLE . ' WHERE ' . $db->sql_in_set('auth_option', $options);
$result = $db->sql_query($sql);
while ($row = $db->sql_fetchrow($result))
{
$sql_ary = array(
'role_id' => $role_id,
'auth_option_id' => $row['auth_option_id'],
'auth_setting' => 1,
);
$sql = 'INSERT INTO ' . ACL_ROLES_DATA_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
$db->sql_query($sql);
}
}
$role_id = false;
}
$message .= '<p style="color: green;">Default permission data has been set.</p><br />';
//Just so we can have more controllz over the sql errors.
$db->sql_return_on_error(true);
//Do the sql stuff
$sql_ary = array();
$sql_ary[] = "ALTER TABLE ". USERS_TABLE ." ADD `user_points` INT( 11 ) NOT NULL DEFAULT '0';";
foreach ($sql_ary as $sql)
{
$message .= '<p style="font-weight: bold;">'.$sql.'</p>';
$result = $db->sql_query($sql);
$message .= (!empty($result)) ? '<p style="color: green;">Query processed succesfully.</p>' : '<p style="color: red;">There was an error while processing this query.</p>';
$message .= '<br />';
}
//Purge Cache
$cache->purge();
add_log('admin', 'LOG_PURGE_CACHE');
$message .= '<p style="color: green;">The cache has been purged.</p><br />';
//Was there error?
$message .= (isset($error)) ? '<p>All queries have been processed, but some errors occured. For security reasons, delete this file from your server.</p>' : '<p>All queries have been processed succesfully. For security reasons, delete this file from your server.</p>';
trigger_error($message);
?>
Update: "Der Fehler kommt erst anch dem Umzug :S Wieso kommt denn der Fehler zur Registrierung?! Da haben wir ja nie was geändert :S"