[pLog-svn] r1609 - plog/trunk
ork at devel.plogworld.net
ork at devel.plogworld.net
Sat Mar 26 20:06:32 GMT 2005
Author: ork
Date: 2005-03-26 20:06:32 +0000 (Sat, 26 Mar 2005)
New Revision: 1609
Modified:
plog/trunk/wizard.php
Log:
constantly used $message (removed all errorMessages), small fix to the
HTTPS check.
Modified: plog/trunk/wizard.php
===================================================================
--- plog/trunk/wizard.php 2005-03-26 20:00:48 UTC (rev 1608)
+++ plog/trunk/wizard.php 2005-03-26 20:06:32 UTC (rev 1609)
@@ -846,9 +846,10 @@
}
if( $errors ) {
- $errorMessage = "Could not save values to the configuration file. Please make sure it is available and that has write permissions for the user under your web server is running.";
+ $message = "Could not save values to the configuration file. Please make sure it is available and
+ that has write permissions for the user under your web server is running.";
$this->_view = new WizardView( "intro" );
- $this->_view->setErrorMessage( $errorMessage );
+ $this->_view->setErrorMessage( $message );
return( false );
}
@@ -905,7 +906,7 @@
$connectionEsablished = true;
} else {
$connectionEsablished = false;
- $errorMessage = "There was an error selecting the database. Please verify the database was already created or check the 'Create database' checkbox.";
+ $message = "There was an error selecting the database. Please verify the database was already created or check the 'Create database' checkbox.";
}
// We were unable to connect to the db and select the right db.. lets try
@@ -914,14 +915,14 @@
if ( !$connectionEsablished ) {
$this->_db = connectDb( true, false );
if( !$this->_db ) {
- $errorMessage = "There was an error connecting to the database. Please check your settings.";
+ $message = "There was an error connecting to the database. Please check your settings.";
}
}
if ( !$connectionEsablished ) {
$this->_view = new WizardView( "step1" );
$this->setDbConfigValues( $this->_view );
- $this->_view->setErrorMessage( $errorMessage );
+ $this->_view->setErrorMessage( $message );
$this->setCommonData( true );
return false;
}
@@ -935,14 +936,14 @@
if( $createDb ) {
$this->_db = connectDb( false, false );
if( !$this->_db->Execute( "CREATE DATABASE ".$this->_database )) {
- $message .= "Error creating the database: ".$this->_db->ErrorMsg();
+ $message = "Error creating the database: ".$this->_db->ErrorMsg();
$this->_view = new WizardView( "step1" );
$this->setDbConfigValues( $this->_view );
$this->_view->setErrorMessage( $message );
$this->setCommonData( true );
return false;
} else {
- $message .= "Database created successfully.<br/>";
+ $message = "Database created successfully.<br/>";
}
}
@@ -973,7 +974,7 @@
// try to guess the url where plog is running
// try to guess the url where plog is running
- $httpProtocol = ($_SERVER["HTTPS"] == "on") ? "https://" : "http://";
+ $httpProtocol = (array_key_exists("HTTPS", $_SERVER) && $_SERVER["HTTPS"] == "on") ? "https://" : "http://";
$httpHost = $_SERVER["HTTP_HOST"];
$requestUrl = $_SERVER["REQUEST_URI"];
$requestUrl = str_replace( "/wizard.php", "", $requestUrl );
More information about the pLog-svn
mailing list