Many a change
This commit is contained in:
parent
5ed03c349a
commit
96998f23ca
3 changed files with 9 additions and 10 deletions
1
inc/.gitignore
vendored
1
inc/.gitignore
vendored
|
@ -1 +0,0 @@
|
||||||
config.inc.php
|
|
|
@ -2,7 +2,7 @@
|
||||||
/**
|
/**
|
||||||
* (c) 2009 BeCast
|
* (c) 2009 BeCast
|
||||||
* -------------------------------------
|
* -------------------------------------
|
||||||
* Filename: config.defult.inc.php
|
* Filename: config.default.inc.php
|
||||||
* Purpose: Configuration
|
* Purpose: Configuration
|
||||||
* CVS Header: $Header$
|
* CVS Header: $Header$
|
||||||
*
|
*
|
|
@ -498,8 +498,8 @@ $config[\'prefix\']=\''.$prefix.'\';
|
||||||
// your Database Sytem
|
// your Database Sytem
|
||||||
$config[\'db_class\']= \''.$driver.'\';
|
$config[\'db_class\']= \''.$driver.'\';
|
||||||
?>';
|
?>';
|
||||||
include dirname(dirname(__FILE__)).'/inc/logger.class.php';
|
include dirname(__FILE__, 2) .'/inc/logger.class.php';
|
||||||
include dirname(dirname(__FILE__)).'/core/database/'.$driver.'.class.php';
|
include dirname(__FILE__, 2) .'/core/database/'.$driver.'.class.php';
|
||||||
try{
|
try{
|
||||||
$db = new db($server, $user, $pass, $db,'utf8', FALSE,TRUE);
|
$db = new db($server, $user, $pass, $db,'utf8', FALSE,TRUE);
|
||||||
$result=$db->query("SHOW TABLES");
|
$result=$db->query("SHOW TABLES");
|
||||||
|
@ -507,7 +507,7 @@ $config[\'db_class\']= \''.$driver.'\';
|
||||||
$error=true;
|
$error=true;
|
||||||
}
|
}
|
||||||
if(!$error){
|
if(!$error){
|
||||||
$datei = fopen(dirname(dirname(__FILE__)).'/config.tmp.php','w');
|
$datei = fopen(dirname(__FILE__, 2) .'/config.tmp.php','w');
|
||||||
fputs($datei,$configdata);
|
fputs($datei,$configdata);
|
||||||
fclose($datei);
|
fclose($datei);
|
||||||
$locked='';
|
$locked='';
|
||||||
|
@ -517,9 +517,9 @@ $config[\'db_class\']= \''.$driver.'\';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(isset($_POST['send'])){
|
if(isset($_POST['send'])){
|
||||||
include dirname(dirname(__FILE__)).'/inc/logger.class.php';
|
include dirname(__FILE__, 2) .'/inc/logger.class.php';
|
||||||
include dirname(dirname(__FILE__)).'/config.tmp.php';
|
include dirname(__FILE__, 2) .'/config.tmp.php';
|
||||||
include dirname(dirname(__FILE__)).'/core/database/'.$config['db_class'].'.class.php';
|
include dirname(__FILE__, 2) .'/core/database/'.$config['db_class'].'.class.php';
|
||||||
|
|
||||||
$configdata='<?php
|
$configdata='<?php
|
||||||
/**
|
/**
|
||||||
|
@ -569,7 +569,7 @@ define(\'INSTALLED\', TRUE);
|
||||||
define(\'CHARSET\', \'UTF-8\');
|
define(\'CHARSET\', \'UTF-8\');
|
||||||
define(\'DEBUG\', FALSE);
|
define(\'DEBUG\', FALSE);
|
||||||
?>';
|
?>';
|
||||||
$datei = fopen(dirname(dirname(__FILE__)).'/inc/config.inc.php','w+');
|
$datei = fopen(dirname(__FILE__, 2) .'/inc/config.inc.php','w+');
|
||||||
fputs($datei,$configdata);
|
fputs($datei,$configdata);
|
||||||
fclose($datei);
|
fclose($datei);
|
||||||
$db = new db($config['host'], $config['user'], $config['pass'], $config['db'],'utf8', FALSE,TRUE);
|
$db = new db($config['host'], $config['user'], $config['pass'], $config['db'],'utf8', FALSE,TRUE);
|
||||||
|
@ -578,7 +578,7 @@ define(\'DEBUG\', FALSE);
|
||||||
$dump->prepare($config['prefix']);
|
$dump->prepare($config['prefix']);
|
||||||
$dump->execute();
|
$dump->execute();
|
||||||
$pdata=$_POST;
|
$pdata=$_POST;
|
||||||
@unlink(dirname(dirname(__FILE__)).'/config.tmp.php');
|
@unlink(dirname(__FILE__, 2) .'/config.tmp.php');
|
||||||
header("Location: install.php?step=user");
|
header("Location: install.php?step=user");
|
||||||
}
|
}
|
||||||
if($pdata['dbprefix']==''){
|
if($pdata['dbprefix']==''){
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue