Update setup.php: Remove phpversion() dependency and fix unterminated line

This commit is contained in:
Jeroen 2022-08-23 09:45:05 +02:00
parent 33dcfbd68e
commit 283e6b2ed0
Signed by: jeroen
GPG Key ID: 7C7028F783798BAB

View File

@ -27,8 +27,8 @@ $html .= '<h1>' . APP_NAME . ' v' . VERSION . '</h1>';
$html .= '<p>It seems that you are running this version of OpenSMTPD Admin for the first time.</p>'; $html .= '<p>It seems that you are running this version of OpenSMTPD Admin for the first time.</p>';
$html .= '<table>'; $html .= '<table>';
$html .= '<tr>'; $html .= '<tr>';
$html .= '<td><strong>PHP version:</strong></td>'; $html .= '<td><strong>PHP:</strong></td>';
$html .= (version_compare(PHP_VERSION, '7.4.0') >= 0) ? '<td><span style="color:green;">' . phpversion() . '</td>' : '<td><span style="color:red;">' . phpversion() . '</span></td>'; $html .= (version_compare(PHP_VERSION, '7.4.0') >= 0) ? '<td><span style="color:green;">At least 7.4</td>' : '<td><span style="color:red;">Unsupported version (=< 7.3)</span></td>';
$html .= '</tr><tr>'; $html .= '</tr><tr>';
$html .= '<td><strong>SQL support:</strong></td>'; $html .= '<td><strong>SQL support:</strong></td>';
$html .= (extension_loaded('mysqli')) ? '<td><span style="color:green;">MySQL/MariaDB</span>' : '<td><span style="color:red;">MySQL/MariaDB</span>'; $html .= (extension_loaded('mysqli')) ? '<td><span style="color:green;">MySQL/MariaDB</span>' : '<td><span style="color:red;">MySQL/MariaDB</span>';
@ -40,7 +40,7 @@ $html .= (function_exists('get_magic_quotes_gpc')) ? ' - <span style="color:gree
$html .= (function_exists('session_start')) ? ' - <span style="color:green;">session_start</span></td>' : ' - <span style="color:red;">session_start</span></td>'; $html .= (function_exists('session_start')) ? ' - <span style="color:green;">session_start</span></td>' : ' - <span style="color:red;">session_start</span></td>';
$html .= '</tr>'; $html .= '</tr>';
$html .= '</table>'; $html .= '</table>';
$html .= '<p>Copy the <pre>config.inc.php.sample</pre> to <pre>config.inc.php</pre>, edit it to your environment and delete <pre>setup.php</pre>' $html .= '<p>Copy the <pre>config.inc.php.sample</pre> to <pre>config.inc.php</pre> and edit it to your environment and delete <em>setup.php</em>';
$html .= '</body>'; $html .= '</body>';
$html .= '</html>'; $html .= '</html>';