MINOR Installer cleanups, removing references to old "command line

installation" which is no longer supported.
MINOR Removed stray semi-colon when showing version in installer
template.
This commit is contained in:
Sean Harvey 2012-04-15 15:05:20 +12:00
parent befbd3e6a8
commit e71b8d6215
2 changed files with 11 additions and 22 deletions

View File

@ -17,7 +17,7 @@
<div id="Header"> <div id="Header">
<h1>SilverStripe</h1> <h1>SilverStripe</h1>
<div class="left"> <div class="left">
<h2>CMS / Framework Installation <?php if($silverstripe_version) echo "<small>Version $silverstripe_version;</small>"; ?></h2> <h2>CMS / Framework Installation <?php if($silverstripe_version) echo "<small>Version $silverstripe_version</small>"; ?></h2>
<p>Thanks for choosing to use SilverStripe! Please follow the instructions below and you should be up in running in no time.<br> <p>Thanks for choosing to use SilverStripe! Please follow the instructions below and you should be up in running in no time.<br>
If you get stuck, head over to the <a href="http://silverstripe.org/installing-silverstripe" target="_blank">installation forum</a>, or check out our list of <a href="http://doc.silverstripe.org/doku.php?id=suggested-web-hosts" target="_blank">suggested web hosts</a> known to work with SilverStripe. If you get stuck, head over to the <a href="http://silverstripe.org/installing-silverstripe" target="_blank">installation forum</a>, or check out our list of <a href="http://doc.silverstripe.org/doku.php?id=suggested-web-hosts" target="_blank">suggested web hosts</a> known to work with SilverStripe.
</p> </p>

View File

@ -353,20 +353,18 @@ class InstallRequirements {
} }
// Check for web server, unless we're calling the installer from the command-line // Check for web server, unless we're calling the installer from the command-line
if(!isset($_SERVER['argv']) || !$_SERVER['argv']) { $this->isRunningWebServer(array("Webserver Configuration", "Server software", "Unknown", $webserver));
$this->isRunningWebServer(array("Webserver Configuration", "Server software", "Unknown", $webserver));
if($isApache) { if($isApache) {
$this->requireApacheRewriteModule('mod_rewrite', array("Webserver Configuration", "URL rewriting support", "You need mod_rewrite to use friendly URLs with SilverStripe, but it is not enabled.")); $this->requireApacheRewriteModule('mod_rewrite', array("Webserver Configuration", "URL rewriting support", "You need mod_rewrite to use friendly URLs with SilverStripe, but it is not enabled."));
} elseif($isIIS) { } elseif($isIIS) {
$this->requireIISRewriteModule('IIS_UrlRewriteModule', array("Webserver Configuration", "URL rewriting support", "You need to enable the IIS URL Rewrite Module to use friendly URLs with SilverStripe, but it is not installed or enabled. Download it for IIS 7 from http://www.iis.net/expand/URLRewrite")); $this->requireIISRewriteModule('IIS_UrlRewriteModule', array("Webserver Configuration", "URL rewriting support", "You need to enable the IIS URL Rewrite Module to use friendly URLs with SilverStripe, but it is not installed or enabled. Download it for IIS 7 from http://www.iis.net/expand/URLRewrite"));
} else { } else {
$this->warning(array("Webserver Configuration", "URL rewriting support", "I can't tell whether any rewriting module is running. You may need to configure a rewriting rule yourself.")); $this->warning(array("Webserver Configuration", "URL rewriting support", "I can't tell whether any rewriting module is running. You may need to configure a rewriting rule yourself."));
}
$this->requireServerVariables(array('SCRIPT_NAME','HTTP_HOST','SCRIPT_FILENAME'), array("Webserver config", "Recognised webserver", "You seem to be using an unsupported webserver. The server variables SCRIPT_NAME, HTTP_HOST, SCRIPT_FILENAME need to be set."));
} }
$this->requireServerVariables(array('SCRIPT_NAME','HTTP_HOST','SCRIPT_FILENAME'), array("Webserver config", "Recognised webserver", "You seem to be using an unsupported webserver. The server variables SCRIPT_NAME, HTTP_HOST, SCRIPT_FILENAME need to be set."));
// Check for GD support // Check for GD support
if(!$this->requireFunction("imagecreatetruecolor", array("PHP Configuration", "GD2 support", "PHP must have GD version 2."))) { if(!$this->requireFunction("imagecreatetruecolor", array("PHP Configuration", "GD2 support", "PHP must have GD version 2."))) {
$this->requireFunction("imagecreate", array("PHP Configuration", "GD2 support", "GD support for PHP not included.")); $this->requireFunction("imagecreate", array("PHP Configuration", "GD2 support", "GD support for PHP not included."));
@ -935,8 +933,7 @@ class Installer extends InstallRequirements {
} }
function install($config) { function install($config) {
if(isset($_SERVER['HTTP_HOST'])) { ?>
?>
<html> <html>
<head> <head>
<title>Installing SilverStripe...</title> <title>Installing SilverStripe...</title>
@ -963,9 +960,6 @@ class Installer extends InstallRequirements {
<p>If you receive a fatal error, refresh this page to continue the installation</p> <p>If you receive a fatal error, refresh this page to continue the installation</p>
<ul> <ul>
<?php <?php
} else {
echo "SILVERSTRIPE COMMAND-LINE INSTALLATION\n\n";
}
$webserver = $this->findWebserver(); $webserver = $this->findWebserver();
$isIIS = $this->isIIS(); $isIIS = $this->isIIS();
@ -1279,11 +1273,6 @@ TEXT;
} }
function checkRewrite() { function checkRewrite() {
if(!isset($_SERVER['HTTP_HOST']) || !$_SERVER['HTTP_HOST']) {
$this->statusMessage("Installer seems to be called from command-line, we're going to assume that rewriting is working.");
return true;
}
$destinationURL = str_replace('install.php', '', $_SERVER['SCRIPT_NAME']) . $destinationURL = str_replace('install.php', '', $_SERVER['SCRIPT_NAME']) .
($this->checkModuleExists('cms') ? 'home/successfullyinstalled?flush=1' : '?flush=1'); ($this->checkModuleExists('cms') ? 'home/successfullyinstalled?flush=1' : '?flush=1');