%s |
';
$error_tpl = '
%s |
%s |
';
$check_titles = Array (
'php_version' => 'PHP version 5.6 or above*',
'url_rewriting' => 'URL rewriting support',
'java' => 'Java template compression',
'composer' => 'Dependencies via Composer*',
'sep1' => 'PHP extensions:',
'memcache' => '- Memory caching support',
'curl' => '- Accessing remote resources (via cURL)*',
'simplexml' => '- XML document processing (via SimpleXML)*',
'spl' => '- Standard PHP Library (SPL)*',
'freetype' => '- TrueType font support (via Freetype)*',
'gd_version' => '- GD Graphics Library 1.8 or above*',
'jpeg' => '- JPEG images support*',
'mysql' => '- Database connectivity (via MySQL)*',
'json' => '- JSON processing support*',
'openssl' => '- OpenSSL support*',
'sep2' => 'PHP settings:',
'memory_limit' => "- Memory requirements changing on the fly",
'display_errors' => "- Prevent script errors in production environment",
'error_reporting' => "- Change error detalization level",
'date.timezone' => "- Web server timezone is explicitly set*",
'variables_order' => '- Needed super-global arrays registered',
'output_buffering' => "- Script output buffering enabled*",
);
$output = sprintf($heading_tpl, 'Server-side requirements');
$check_results = $this->toolkit->CallPrerequisitesMethod('core/', 'CheckSystemRequirements');
foreach ($check_titles AS $key => $title) {
if ( substr($key, 0, 3) == 'sep' ) {
$check_result = '';
}
else {
$check_result = $check_results[$key] ? '[PASSED]' : '[FAILED]';
}
$output .= sprintf($error_tpl, $title, $check_result);
}
$output .= sprintf($heading_tpl, 'Client-side requirements', 'text');
$output .= sprintf($error_tpl, 'Cookies enabled', '[FAILED]');
$output .= sprintf($error_tpl, 'JavaScript enabled', '[FAILED]');
$output .= '';
$output .= '';
$output .= "";
echo $output;
?>