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