1*aec1a091SAndreas Gohr<?php 2*aec1a091SAndreas Gohr 3*aec1a091SAndreas Gohr// platform_check.php @generated by Composer 4*aec1a091SAndreas Gohr 5*aec1a091SAndreas Gohr$issues = array(); 6*aec1a091SAndreas Gohr 7*aec1a091SAndreas Gohrif (!(PHP_VERSION_ID >= 50300)) { 8*aec1a091SAndreas Gohr $issues[] = 'Your Composer dependencies require a PHP version ">= 5.3.0". You are running ' . PHP_VERSION . '.'; 9*aec1a091SAndreas Gohr} 10*aec1a091SAndreas Gohr 11*aec1a091SAndreas Gohrif ($issues) { 12*aec1a091SAndreas Gohr if (!headers_sent()) { 13*aec1a091SAndreas Gohr header('HTTP/1.1 500 Internal Server Error'); 14*aec1a091SAndreas Gohr } 15*aec1a091SAndreas Gohr if (!ini_get('display_errors')) { 16*aec1a091SAndreas Gohr if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') { 17*aec1a091SAndreas Gohr fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL); 18*aec1a091SAndreas Gohr } elseif (!headers_sent()) { 19*aec1a091SAndreas Gohr echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL; 20*aec1a091SAndreas Gohr } 21*aec1a091SAndreas Gohr } 22*aec1a091SAndreas Gohr trigger_error( 23*aec1a091SAndreas Gohr 'Composer detected issues in your platform: ' . implode(' ', $issues), 24*aec1a091SAndreas Gohr E_USER_ERROR 25*aec1a091SAndreas Gohr ); 26*aec1a091SAndreas Gohr} 27