When I do the initial install I get this:
Warning: mysql_connect() [function.mysql-connect]: Can't connect to MySQL server on 'localhost' (10061) in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 18
Warning: mysql_select_db(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 19
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 20
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 22
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in D:\Hosting\6585577\html\rhythmmovement\install\index.php on line 24
Installation successfull
File "installdone.txt" has been created, if You want to run the "Installation wizard" again, You must delete that file.
Default username and password is "admin".
You can now go to Your Blog.
here is the install index.php file contents:
<?php
function str_replace_once($search, $replace, $target) {
$startPos = strpos($target, $search);
if ( !($startPos === 0 || $startPos > 0) ) return $target;
$endPos = $startPos + strlen($search);
return substr( $target, 0, $startPos ) . $replace . substr( $target, $endPos );
}
if ( file_exists('installdone.txt') ) exit;
if (substr($_SERVER['DOCUMENT_ROOT'], -1)=='/' || substr($_SERVER['DOCUMENT_ROOT'], -1)=='\\') {;} else { $finalslash=DIRECTORY_SEPARATOR; }
define('ospath', rtrim(dirname(__FILE__), 'install') );
define('basepath', rtrim(($_SERVER['SERVER_PORT']==443&&$_SERVER['HTTPS'])?'':''.$_SERVER['SERVER_NAME'].'/'.str_replace_once($_SERVER['DOCUMENT_ROOT'].$finalslash, '', ospath), '/') );
function importTables() {
$data = file('dbinit.sql');
$link = mysql_connect($_POST['dbserver'], $_POST['dbuser'], $_POST['dbpass']);
mysql_select_db($_POST['dbname'], $link);
mysql_query('set names utf8;', $link);
foreach ( $data as $line ) {
mysql_query($line, $link);
}
mysql_query('insert into blog_articles_settings(`id`, `path`, `background`, `logo`, `mp3`, `comments`, `copyright`, `sitepath`, `fbid`, `fbnum`, `fb`, `fbdescription`, `tw`, `twdescription`, `ms`, `msdescription`, `ld`, `lddescription`, `di`, `didescription`, `yt`, `ytdescription`, `vm`, `vmdescription`, `fl`, `fldescription`, `lf`, `lfdescription`, `tb`, `tbdescription`, `su`, `sudescription`, `dl`, `dldescription`, `rd`, `rddescription`, `tr`, `trdescription`) values("1", "'.('http://'.basepath).'", "null", "null", "null", "No", "2010 Flash Blog Special. All right reserved.", "", "", "10" , "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "") ;', $link);
if ($link) mysql_close($link);
return true;
};
$installationDone = false;
if (!is_writeable('./') || !is_writeable('./../') || !is_writeable('./../uf') || !is_writeable('./../uf/advertising')|| !is_writeable('./../uf/article')|| !is_writeable('./../uf/settings')|| !is_writeable('./../uf/userfiles')) { $_POST['step']=null; }
if ( $_POST['step'] ) {
switch ( $_POST['step'] ) {
case '2' :
if ( $_POST['sitepath'] && $_POST['sitedomain'] && $_POST['dbserver'] && $_POST['dbuser'] && $_POST['dbpass'] && $_POST['dbname']) {
if(!is_dir("./../uf/userfiles/1")) mkdir("./../uf/userfiles/1", 0777);
$configData .= '<?php'."\n";
$configData .= "\t".' define("DB_HOST", "'.$_POST['dbserver'].'");'."\n";
$configData .= "\t".' define("DB_USER", "'.$_POST['dbuser'].'");'."\n";
$configData .= "\t".' define("DB_PASS", "'.$_POST['dbpass'].'");'."\n";
$configData .= "\t".' define("DB_NAME", "'.$_POST['dbname'].'");'."\n";
$configData .= "\t".' define("SITE_PATH", "'.$_POST['sitepath'].'");'."\n";
$configData .= "\t".' define("SITE_DOMAIN", "'.$_POST['sitedomain'].'");'."\n";
$configData .= "\t".' $sitename = "'.$_POST['sitename'].'";'."\n";
$configData .= "\t".' $sitemail = "'.$_POST['sitemail'].'";'."\n";
$configData .= "\t".' ini_set("include_path", SITE_PATH."lib");'."\n";
$configData .= '?>';
if ( @file_put_contents('../site.defs.php', $configData) && importTables() ) {
@touch('installdone.txt');
$installationDone = true;
}
}
break;
}
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title> Installation wizard </title>
<style type='text/css'>
body,table,input{font:9pt arial;}.titleDiv{
font:12pt arial;
color:#444;
background:#E9E9E9;
padding:4px;
font-weight:bold;
border: 1px solid #444444;
}.centered{
margin-left:0%;
}.container{
padding:4px;
width:500px;
border:solid 1px #999;
background:#fafafa;
text-align: left;
}.shortNote{
background:#666;
color:#eee;
font:8pt arial;
padding:10px;
line-height:150%;
border: 1px solid #444444;
border-bottom: solid 1px #E9E9E9;
}label{
width:240px;
display:block;
background:##E9E9E9;
padding:2px;
}.shortNote2{
background:#272727;
color:#eee;
font:8pt arial;
border-top:solid 1px #444;
border-bottom:solid 1px #444;
padding:10px;
line-height:150%;
}label{
width:240px;
display:block;
padding:2px;
}.width240{
width:472px;
padding:2px;
}.submitDiv{
margin-top:10px;
background:#666;
padding:4px;
text-align:right;
border: solid 1px #E9E9E9;
}.submitButton{font:11pt arial;padding:2px;width:60px;}.installationDoneDiv{
font:10pt arial;
line-height:150%;
background:#666;
color:#FFFBF0;
padding:10px;
}.installationDoneDiv a{
text-decoration:none;
font:12pt arial;
font-weight:bold;
color:#FFFBF0;
}
body {
background-color: #E2E0E0;
}
.nopermdiv {
background:#e55;
color:#fff;
border:solid 1px #422;
padding:10px;
margin-bottom:1px;
}
</style>
</head>
<body >
<div class='centered'>
<div align="center"><div class='container'>
<?php if ( !$installationDone ) { ?>
<div class='titleDiv'>Installation wizard</div>
<div class='shortNote'>Just enter the settings and press the "Install" button.<br /> Once the installation is done, the file "installdone.txt" will be created in order to prevent further executions of the installation script.<br /> The default username and password is "<b>admin</b>"</div>
<?if (!is_writeable('./') || !is_writeable('./../') || !is_writeable('./../uf') || !is_writeable('./../uf/advertising')|| !is_writeable('./../uf/article')|| !is_writeable('./../uf/settings')|| !is_writeable('./../uf/userfiles')) { ?>
<div class='nopermdiv'>Please give WRITE permissions to this script for the following directories<br />
<?=$_POST['sitepath']!=''?$_POST['sitepath']:ospath?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'install/':ospath.'install/')?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'uf/':ospath.'uf/')?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'uf/advertising/':ospath.'uf/advertising/')?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'uf/article/':ospath.'uf/article/')?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'uf/settings/':ospath.'uf/settings/')?>
<?='<br />'.($_POST['sitepath']!=''?$_POST['sitepath'].'uf/userfiles/':ospath.'uf/userfiles/')?>
</div>
<? } ?>
<div class='shortNote2'>
<form action='<?$_SERVER['PHP_SELF']?>' method='post'>
<label for='sitename'>Site name </label>
<input type='text' name='sitename' class='width240' value="<?=$_POST['sitename']!=''?$_POST['sitename']:''?>" />
<label for='sitemail'>Site e-mail</label>
<input type='text' name='sitemail' class='width240' value="<?=$_POST['sitemail']!=''?$_POST['sitemail']:''?>" />
<label for='sitepath'>Site path</label>
<input type='text' name='sitepath' value="<?=$_POST['sitepath']!=''?$_POST['sitepath']:ospath?>" class='width240' />
<label for='sitedomain'>Site domain</label>
<input type='text' name='sitedomain' value="<?=$_POST['sitedomain']!=''?$_POST['sitedomain']:basepath?>" class='width240' />
<label for='dbserver'>Database server</label>
<input type='text' name='dbserver' value="<?=$_POST['dbserver']!=''?$_POST['dbserver']:'localhost'?>" class='width240' />
<label for='dbuser'>Database user</label>
<input type='text' name='dbuser' value="<?=$_POST['dbuser']!=''?$_POST['dbuser']:''?>" class='width240' />
<label for='dbpass'>Database password</label>
<input type='password' name='dbpass' value="<?=$_POST['dbpass']!=''?$_POST['dbpass']:''?>" class='width240' />
<label for='dbname'>Database name</label>
<input type='text' name='dbname' value="<?=$_POST['dbname']!=''?$_POST['dbname']:''?>" class='width240' />
<div class='submitDiv'>
<input type='hidden' name='step' value='2'>
<input type='submit' value='Install' class='submitButton'>
</div>
</form>
</div></div>
<?php } else { ?>
<div class='installationDoneDiv'>
Installation successfull<br />
File "installdone.txt" has been created, if You want to run the "Installation wizard" again, You must delete that file.<br />
Default username and password is "<b>admin</b>".<br />
<a href="http://<?=$_POST['sitedomain']!=''?$_POST['sitedomain']:basepath?>">You can now go to Your Blog.</a>
</div>
<? } ?>
</div>
</div>
then I go to the site http://www.rhythmmovement.com/rhythmmovement/ and get
Parse error: syntax error, unexpected T_STRING in D:\Hosting\6585577\html\rhythmmovement\site.defs.php on line 7
and the contents of that file (site.defs.php) is the following
<?php
define("DB_HOST", "localhost");
define("DB_USER", "rmhost");
define("DB_PASS", "Paxxxxxxx7");
define("DB_NAME", "PSC");
define("SITE_PATH", "D:\Hosting\6585577\html\rhythmmovement\");
define("SITE_DOMAIN", "www.rhythmmovement.com/rhythmmovement\");
$sitename = "rhythmmovement.com";
$sitemail = "host@rhythmmovement.com";
ini_set("include_path", SITE_PATH."lib");
?>
This is everything. Please help...