Merge pull request #206 from textagroup/master

Enhancement to display location of php.ini file when errors exist in install
This commit is contained in:
Sean Harvey 2012-03-04 12:18:14 -08:00
commit b48d2a628a
2 changed files with 9 additions and 0 deletions

View File

@ -34,6 +34,9 @@
You aren't currently able to install the software. Please <a href="#requirements">see below</a> for details.<br> You aren't currently able to install the software. Please <a href="#requirements">see below</a> for details.<br>
If you are having problems meeting the requirements, see the <a href="http://doc.silverstripe.org/doku.php?id=server-requirements">server requirements wiki page</a>. If you are having problems meeting the requirements, see the <a href="http://doc.silverstripe.org/doku.php?id=server-requirements">server requirements wiki page</a>.
</p> </p>
<?php if (isset($phpIniLocation)) { ?>
<p>Your php.ini file is located at <?php echo $phpIniLocation; ?></p>
<?php } ?>
<?php } else { ?> <?php } else { ?>
<?php if($alreadyInstalled) { ?> <?php if($alreadyInstalled) { ?>
<div class="warning"> <div class="warning">

View File

@ -160,6 +160,12 @@ if($req->isIIS()) {
if($req->hasErrors()) { if($req->hasErrors()) {
$hasErrorOtherThanDatabase = true; $hasErrorOtherThanDatabase = true;
if ( function_exists('php_ini_loaded_file')) {
// show the location of the php.ini if any issues exist
$phpIniLocation = php_ini_loaded_file();
} else {
$phpIniLocation = null;
}
} }
if($databaseConfig) { if($databaseConfig) {