Hallo,
ist eigtl. keinen eigenen Thread wert, aber anders gehts schlecht

Im oben genannten Downloadfile ist das db_update File irgendwie nicht richtig...
Zumindest bekomm ich ein Could not connect to database...
Code: Alles auswählen
<?php
define('IN_PHPBB', 1);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'config.'.$phpEx);
include($phpbb_root_path . 'common.'.$phpEx);
include($phpbb_root_path . 'includes/constants.'.$phpEx);
include($phpbb_root_path . 'includes/db.'.$phpEx);
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
//
// End session management
//
//
//
// Restrict to members:
if( !$userdata['session_logged_in'] )
{
header("Location: " . append_sid("login.$phpEx?redirect=full_db_backup_db_install.$phpEx", true));
exit;
}
//
//
if ( $userdata['user_level'] == ADMIN )
{
}
else
{
message_die(GENERAL_MESSAGE, $lang['Not_Authorised'], $lang['Not_Authorised']);
exit;
}
echo '<html>
<head>
<title>SQL-DB-Installer - Full DB BackUp MOD</title>
</head>
<body>
<h1>SQL-DB-Installer - Full DB BackUp MOD</h1>
<hr />';
if (!isset($HTTP_GET_VARS['install'])) {
echo '<a href="?install=1">Please click here | Bitte hier klicken</a>';
}
else {
$queries = array(
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript1_active', '1')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript1_gzip', '0')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript2_active', '1')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript2_gzip', '0')",
"INSERT INTO " . $table_prefix . "config VALUES ('backup_path', '.././db_backup_files')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupcount1', '3')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupcount2', '3')"
);
$success = true;
foreach($queries as $query) {
if (!$db->sql_query($query)) {
echo '<font color="red">An error occurred ! Changes have not been entered successfully !<br /><br />Es Fehler ist aufgetreten ! Änderung nicht erfolgreich eingetragen !</font><br /><br />';
echo mysql_error();
$success = false;
break;
}
}
if ($success) {
echo '<font color="green">DB-Changes have been entered successfully. You should delete this SQL-DB-Installer as soon as possible !<br /><br />DB-Änderung wurde erfolgreich ausgeführt. Du solltest diesen SQL-DB-Installer sobald wie möglich löschen !';
}
}
?>
Sind das die DB Changes, die sonst immer in ner Mod Anleitung stehen?
Dann mach ich das File mit meinem db_generator

Code: Alles auswählen
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript1_active', '1')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript1_gzip', '0')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript2_active', '1')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupscript2_gzip', '0')",
"INSERT INTO " . $table_prefix . "config VALUES ('backup_path', '.././db_backup_files')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupcount1', '3')",
"INSERT INTO " . $table_prefix . "config VALUES ('backupcount2', '3')"
bazo