3v4l.org

run code in 300+ PHP versions simultaneously
<?php header("Cache-Control: max-age=301, must-revalidate, stale-while-revalidate=150, stale-if-error=60"); $env = "int";//getenv("SERVER_ENV"); $INSTRUCTOR_LOCATIONS = array( 'sandbox' => 'http://sandbox.bbc.co.uk:9000/', 'int' => 'http://crb-brb-instructor.int.api.bbci.co.uk/', 'test' => 'http://crb-brb-instructor.test.api.bbci.co.uk/', 'stage' => 'http://crb-brb-instructor.api.bbci.co.uk/', 'live' => 'http://crb-brb-instructor.api.bbci.co.uk/' ); $PLATFORMS = array('freeview', 'freesat'); $REGISTRATION_ENABLED_ON = array('sandbox', 'int', 'test', 'stage', 'live'); $instructorLocation = (isset($INSTRUCTOR_LOCATIONS[$env])) ? $INSTRUCTOR_LOCATIONS[$env] : 'http://config-error/'; $registrationEnabled = (in_array($env, $REGISTRATION_ENABLED_ON)) ? 'true' : 'false'; //$platformName = isset($_GET['platformName']) ? $_GET['platformName'] : ''; //$platform = in_array($platformName, $PLATFORMS) ? $platformName : 'freesat'; // Helper methods function printRCValue($tagName, $value) { print sprintf("@%s|%s|\n", $tagName, $value); } // Generate RC file response printRCValue('ServerEnvironment', $env); printRCValue('ServerLocation', "http://open.$env.bbc.co.uk/smartbridge/"); printRCValue('InstructorLocation', $instructorLocation); printRCValue('RegistrationEnabled', $registrationEnabled); //printRCValue('MakeAndModelServiceLocation', "http://open.int.bbc.co.uk/smartbridge/content-provider/platform/$platform/makeAndModel.rc?whoami=PANT14A01");

preferences:
50.29 ms | 402 KiB | 5 Q