Added several additional checks to install.php, fixes #31

This commit is contained in:
Woody Gilk 2009-07-12 10:04:54 -05:00
parent 7d21965beb
commit 1b199cf239

View file

@ -80,6 +80,14 @@
<td class="pass">Pass</td>
<?php endif ?>
</tr>
<tr>
<th>SPL Enabled</th>
<?php if (function_exists('spl_autoload_register')): ?>
<td class="pass">Pass</td>
<?php else: $failed = TRUE ?>
<td class="fail">PHP <a href="http://www.php.net/spl">SPL</a> is either not loaded or not compiled in.</td>
<?php endif ?>
</tr>
<tr>
<th>Reflection Enabled</th>
<?php if (class_exists('ReflectionClass')): ?>
@ -116,10 +124,10 @@
<?php endif ?>
<tr>
<th>URI Determination</th>
<?php if (isset($_SERVER['REQUEST_URI']) OR isset($_SERVER['PHP_SELF'])): ?>
<?php if (isset($_SERVER['REQUEST_URI']) OR isset($_SERVER['PHP_SELF']) OR isset($_SERVER['PATH_INFO'])): ?>
<td class="pass">Pass</td>
<?php else: $failed = TRUE ?>
<td class="fail">Neither <code>$_SERVER['REQUEST_URI']</code> or <code>$_SERVER['PHP_SELF']</code> is available.</td>
<td class="fail">Neither <code>$_SERVER['REQUEST_URI']</code>, <code>$_SERVER['PHP_SELF']</code>, or <code>$_SERVER['PATH_INFO']</code> is available.</td>
<?php endif ?>
</tr>
</table>
@ -130,7 +138,7 @@
<p id="results" class="pass"> Your environment passed all requirements.<br />
Remove or rename the <code>install<?php echo EXT ?></code> file now.</p>
<?php endif ?>
<h1>Optional Tests</h1>
<p>
@ -143,7 +151,31 @@
<?php if (extension_loaded('curl')): ?>
<td class="pass">Pass</td>
<?php else: ?>
<td class="fail">Kohana requires cURL to make use of the remote helper.</td>
<td class="fail">Kohana requires <a href="http://php.net/curl">cURL</a> for the Remote class.</td>
<?php endif ?>
</tr>
<tr>
<th>mcrypt Enabled</th>
<?php if (extension_loaded('mcrypt')): ?>
<td class="pass">Pass</td>
<?php else: ?>
<td class="fail">Kohana requires <a href="http://php.net/mcrypt">mcrypt</a> for the Encrypt class.</td>
<?php endif ?>
</tr>
<tr>
<th>GD Enabled</th>
<?php if (function_exists('gd_info')): ?>
<td class="pass">Pass</td>
<?php else: ?>
<td class="fail">Kohana requires <a href="http://php.net/pdo">GD</a> v2 for the Image class.</td>
<?php endif ?>
</tr>
<tr>
<th>PDO Enabled</th>
<?php if (class_exists('PDO')): ?>
<td class="pass">Pass</td>
<?php else: ?>
<td class="fail">Kohana can use <a href="http://php.net/pdo">PDO</a> to support additional databases.</td>
<?php endif ?>
</tr>
</table>