I also created a brand new slim composer checkout.
Then only 1 index.php file with the following:
<?php
use \Psr\Http\Message\ServerRequestInterface as Request;
use \Psr\Http\Message\ResponseInterface as Response;
require '../vendor/autoload.php';
$app = new \Slim\App;
$app->get('/hello/{name}', function (Request $request, Response $response) {
var_dump($request); die;
return $response;
});
$app->run();
And the var_dump($request) presents the following. It looks like there are multiple instances of SERVER data, like example SERVER_SOFTWARE. This seems very unnecessary and strange to me:
> object(Slim\Http\Request)#38 (15) { ["method":protected]=> string(3) "GET" ["originalMethod":protected]=> string(3) "GET" ["uri":protected]=> object(Slim\Http\Uri)#28 (9) { ["scheme":protected]=> string(4) "http" ["user":protected]=> string(0) "" ["password":protected]=> string(0) "" ["host":protected]=> string(9) "localhost" ["port":protected]=> int(80) ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["path":protected]=> string(10) "hello/mama" ["query":protected]=> string(0) "" ["fragment":protected]=> string(0) "" } ["requestTarget":protected]=> NULL ["queryParams":protected]=> NULL ["cookies":protected]=> array(0) { } ["serverParams":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } ["attributes":protected]=> object(Slim\Collection)#47 (1) { ["data":protected]=> array(3) { ["route"]=> object(Slim\Route)#23 (13) { ["methods":protected]=> array(1) { [0]=> string(3) "GET" } ["identifier":protected]=> string(6) "route0" ["name":protected]=> NULL ["groups":protected]=> array(0) { } ["finalized":"Slim\Route":private]=> bool(true) ["outputBuffering":protected]=> string(6) "append" ["arguments":protected]=> array(1) { ["name"]=> string(4) "mama" } ["callable":protected]=> object(Closure)#19 (2) { ["this"]=> object(Slim\Container)#2 (7) { ["defaultSettings":"Slim\Container":private]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } ["values":"Pimple\Container":private]=> array(11) { ["settings"]=> object(Slim\Collection)#20 (1) { ["data":protected]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } } ["environment"]=> object(Slim\Http\Environment)#24 (1) { ["data":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } } ["request"]=> object(Slim\Http\Request)#30 (15) { ["method":protected]=> string(3) "GET" ["originalMethod":protected]=> string(3) "GET" ["uri":protected]=> object(Slim\Http\Uri)#28 (9) { ["scheme":protected]=> string(4) "http" ["user":protected]=> string(0) "" ["password":protected]=> string(0) "" ["host":protected]=> string(9) "localhost" ["port":protected]=> int(80) ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["path":protected]=> string(10) "hello/mama" ["query":protected]=> string(0) "" ["fragment":protected]=> string(0) "" } ["requestTarget":protected]=> NULL ["queryParams":protected]=> NULL ["cookies":protected]=> array(0) { } ["serverParams":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } ["attributes":protected]=> object(Slim\Collection)#31 (1) { ["data":protected]=> array(0) { } } ["bodyParsed":protected]=> bool(false) ["bodyParsers":protected]=> array(4) { ["application/json"]=> object(Closure)#33 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["application/xml"]=> object(Closure)#34 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["text/xml"]=> object(Closure)#35 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["application/x-www-form-urlencoded"]=> object(Closure)#36 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } } ["uploadedFiles":protected]=> array(0) { } ["validMethods":protected]=> array(9) { ["CONNECT"]=> int(1) ["DELETE"]=> int(1) ["GET"]=> int(1) ["HEAD"]=> int(1) ["OPTIONS"]=> int(1) ["PATCH"]=> int(1) ["POST"]=> int(1) ["PUT"]=> int(1) ["TRACE"]=> int(1) } ["protocolVersion":protected]=> string(3) "1.1" ["headers":protected]=> object(Slim\Http\Headers)#29 (1) { ["data":protected]=> array(8) { ["host"]=> array(2) { ["value"]=> array(1) { [0]=> string(9) "localhost" } ["originalKey"]=> string(4) "Host" } ["connection"]=> array(2) { ["value"]=> array(1) { [0]=> string(10) "keep-alive" } ["originalKey"]=> string(15) "HTTP_CONNECTION" } ["upgrade-insecure-requests"]=> array(2) { ["value"]=> array(1) { [0]=> string(1) "1" } ["originalKey"]=> string(30) "HTTP_UPGRADE_INSECURE_REQUESTS" } ["user-agent"]=> array(2) { ["value"]=> array(1) { [0]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" } ["originalKey"]=> string(15) "HTTP_USER_AGENT" } ["accept"]=> array(2) { ["value"]=> array(1) { [0]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" } ["originalKey"]=> string(11) "HTTP_ACCEPT" } ["dnt"]=> array(2) { ["value"]=> array(1) { [0]=> string(1) "1" } ["originalKey"]=> string(8) "HTTP_DNT" } ["accept-encoding"]=> array(2) { ["value"]=> array(1) { [0]=> string(23) "gzip, deflate, sdch, br" } ["originalKey"]=> string(20) "HTTP_ACCEPT_ENCODING" } ["accept-language"]=> array(2) { ["value"]=> array(1) { [0]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" } ["originalKey"]=> string(20) "HTTP_ACCEPT_LANGUAGE" } } } ["body":protected]=> object(Slim\Http\RequestBody)#18 (7) { ["stream":protected]=> resource(4) of type (stream) ["meta":protected]=> NULL ["readable":protected]=> NULL ["writable":protected]=> NULL ["seekable":protected]=> NULL ["size":protected]=> NULL ["isPipe":protected]=> NULL } } ["response"]=> object(Slim\Http\Response)#26 (5) { ["status":protected]=> int(200) ["reasonPhrase":protected]=> string(0) "" ["protocolVersion":protected]=> string(3) "1.1" ["headers":protected]=> object(Slim\Http\Headers)#27 (1) { ["data":protected]=> array(1) { ["content-type"]=> array(2) { ["value"]=> array(1) { [0]=> string(24) "text/html; charset=UTF-8" } ["originalKey"]=> string(12) "Content-Type" } } } ["body":protected]=> object(Slim\Http\Body)#25 (7) { ["stream":protected]=> resource(2) of type (stream) ["meta":protected]=> NULL ["readable":protected]=> NULL ["writable":protected]=> NULL ["seekable":protected]=> NULL ["size":protected]=> NULL ["isPipe":protected]=> NULL } } ["router"]=> object(Slim\Router)#21 (8) { ["container":protected]=> *RECURSION* ["routeParser":protected]=> object(FastRoute\RouteParser\Std)#22 (0) { } ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["cacheFile":protected]=> bool(false) ["routes":protected]=> array(1) { ["route0"]=> *RECURSION* } ["routeCounter":protected]=> int(1) ["routeGroups":protected]=> array(0) { } ["dispatcher":protected]=> object(FastRoute\Dispatcher\GroupCountBased)#42 (2) { ["staticRouteMap":protected]=> array(0) { } ["variableRouteData":protected]=> array(1) { ["GET"]=> array(1) { [0]=> array(2) { ["regex"]=> string(22) "~^(?|/hello/([^/]+))$~" ["routeMap"]=> array(1) { [2]=> array(2) { [0]=> string(6) "route0" [1]=> array(1) { ["name"]=> string(4) "name" } } } } } } } } ["foundHandler"]=> object(Slim\Handlers\Strategies\RequestResponse)#41 (0) { } ["phpErrorHandler"]=> object(Closure)#13 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["errorHandler"]=> object(Closure)#14 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["notFoundHandler"]=> object(Closure)#15 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["notAllowedHandler"]=> object(Closure)#16 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["callableResolver"]=> object(Slim\CallableResolver)#40 (1) { ["container":"Slim\CallableResolver":private]=> *RECURSION* } } ["factories":"Pimple\Container":private]=> object(SplObjectStorage)#4 (1) { ["storage":"SplObjectStorage":private]=> array(0) { } } ["protected":"Pimple\Container":private]=> object(SplObjectStorage)#5 (1) { ["storage":"SplObjectStorage":private]=> array(0) { } } ["frozen":"Pimple\Container":private]=> array(7) { ["settings"]=> bool(true) ["router"]=> bool(true) ["response"]=> bool(true) ["environment"]=> bool(true) ["request"]=> bool(true) ["callableResolver"]=> bool(true) ["foundHandler"]=> bool(true) } ["raw":"Pimple\Container":private]=> array(7) { ["settings"]=> object(Closure)#6 (2) { ["static"]=> array(2) { ["userSettings"]=> array(0) { } ["defaultSettings"]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } } ["this"]=> *RECURSION* } ["router"]=> object(Closure)#11 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["response"]=> object(Closure)#10 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["environment"]=> object(Closure)#8 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["request"]=> object(Closure)#9 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["callableResolver"]=> object(Closure)#17 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["foundHandler"]=> object(Closure)#12 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } } ["keys":"Pimple\Container":private]=> array(11) { ["settings"]=> bool(true) ["environment"]=> bool(true) ["request"]=> bool(true) ["response"]=> bool(true) ["router"]=> bool(true) ["foundHandler"]=> bool(true) ["phpErrorHandler"]=> bool(true) ["errorHandler"]=> bool(true) ["notFoundHandler"]=> bool(true) ["notAllowedHandler"]=> bool(true) ["callableResolver"]=> bool(true) } } ["parameter"]=> array(2) { ["$request"]=> string(10) "" ["$response"]=> string(10) "" } } ["container":protected]=> object(Slim\Container)#2 (7) { ["defaultSettings":"Slim\Container":private]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } ["values":"Pimple\Container":private]=> array(11) { ["settings"]=> object(Slim\Collection)#20 (1) { ["data":protected]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } } ["environment"]=> object(Slim\Http\Environment)#24 (1) { ["data":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } } ["request"]=> object(Slim\Http\Request)#30 (15) { ["method":protected]=> string(3) "GET" ["originalMethod":protected]=> string(3) "GET" ["uri":protected]=> object(Slim\Http\Uri)#28 (9) { ["scheme":protected]=> string(4) "http" ["user":protected]=> string(0) "" ["password":protected]=> string(0) "" ["host":protected]=> string(9) "localhost" ["port":protected]=> int(80) ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["path":protected]=> string(10) "hello/mama" ["query":protected]=> string(0) "" ["fragment":protected]=> string(0) "" } ["requestTarget":protected]=> NULL ["queryParams":protected]=> NULL ["cookies":protected]=> array(0) { } ["serverParams":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } ["attributes":protected]=> object(Slim\Collection)#31 (1) { ["data":protected]=> array(0) { } } ["bodyParsed":protected]=> bool(false) ["bodyParsers":protected]=> array(4) { ["application/json"]=> object(Closure)#33 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["application/xml"]=> object(Closure)#34 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["text/xml"]=> object(Closure)#35 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } ["application/x-www-form-urlencoded"]=> object(Closure)#36 (2) { ["this"]=> *RECURSION* ["parameter"]=> array(1) { ["$input"]=> string(10) "" } } } ["uploadedFiles":protected]=> array(0) { } ["validMethods":protected]=> array(9) { ["CONNECT"]=> int(1) ["DELETE"]=> int(1) ["GET"]=> int(1) ["HEAD"]=> int(1) ["OPTIONS"]=> int(1) ["PATCH"]=> int(1) ["POST"]=> int(1) ["PUT"]=> int(1) ["TRACE"]=> int(1) } ["protocolVersion":protected]=> string(3) "1.1" ["headers":protected]=> object(Slim\Http\Headers)#29 (1) { ["data":protected]=> array(8) { ["host"]=> array(2) { ["value"]=> array(1) { [0]=> string(9) "localhost" } ["originalKey"]=> string(4) "Host" } ["connection"]=> array(2) { ["value"]=> array(1) { [0]=> string(10) "keep-alive" } ["originalKey"]=> string(15) "HTTP_CONNECTION" } ["upgrade-insecure-requests"]=> array(2) { ["value"]=> array(1) { [0]=> string(1) "1" } ["originalKey"]=> string(30) "HTTP_UPGRADE_INSECURE_REQUESTS" } ["user-agent"]=> array(2) { ["value"]=> array(1) { [0]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" } ["originalKey"]=> string(15) "HTTP_USER_AGENT" } ["accept"]=> array(2) { ["value"]=> array(1) { [0]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" } ["originalKey"]=> string(11) "HTTP_ACCEPT" } ["dnt"]=> array(2) { ["value"]=> array(1) { [0]=> string(1) "1" } ["originalKey"]=> string(8) "HTTP_DNT" } ["accept-encoding"]=> array(2) { ["value"]=> array(1) { [0]=> string(23) "gzip, deflate, sdch, br" } ["originalKey"]=> string(20) "HTTP_ACCEPT_ENCODING" } ["accept-language"]=> array(2) { ["value"]=> array(1) { [0]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" } ["originalKey"]=> string(20) "HTTP_ACCEPT_LANGUAGE" } } } ["body":protected]=> object(Slim\Http\RequestBody)#18 (7) { ["stream":protected]=> resource(4) of type (stream) ["meta":protected]=> NULL ["readable":protected]=> NULL ["writable":protected]=> NULL ["seekable":protected]=> NULL ["size":protected]=> NULL ["isPipe":protected]=> NULL } } ["response"]=> object(Slim\Http\Response)#26 (5) { ["status":protected]=> int(200) ["reasonPhrase":protected]=> string(0) "" ["protocolVersion":protected]=> string(3) "1.1" ["headers":protected]=> object(Slim\Http\Headers)#27 (1) { ["data":protected]=> array(1) { ["content-type"]=> array(2) { ["value"]=> array(1) { [0]=> string(24) "text/html; charset=UTF-8" } ["originalKey"]=> string(12) "Content-Type" } } } ["body":protected]=> object(Slim\Http\Body)#25 (7) { ["stream":protected]=> resource(2) of type (stream) ["meta":protected]=> NULL ["readable":protected]=> NULL ["writable":protected]=> NULL ["seekable":protected]=> NULL ["size":protected]=> NULL ["isPipe":protected]=> NULL } } ["router"]=> object(Slim\Router)#21 (8) { ["container":protected]=> *RECURSION* ["routeParser":protected]=> object(FastRoute\RouteParser\Std)#22 (0) { } ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["cacheFile":protected]=> bool(false) ["routes":protected]=> array(1) { ["route0"]=> *RECURSION* } ["routeCounter":protected]=> int(1) ["routeGroups":protected]=> array(0) { } ["dispatcher":protected]=> object(FastRoute\Dispatcher\GroupCountBased)#42 (2) { ["staticRouteMap":protected]=> array(0) { } ["variableRouteData":protected]=> array(1) { ["GET"]=> array(1) { [0]=> array(2) { ["regex"]=> string(22) "~^(?|/hello/([^/]+))$~" ["routeMap"]=> array(1) { [2]=> array(2) { [0]=> string(6) "route0" [1]=> array(1) { ["name"]=> string(4) "name" } } } } } } } } ["foundHandler"]=> object(Slim\Handlers\Strategies\RequestResponse)#41 (0) { } ["phpErrorHandler"]=> object(Closure)#13 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["errorHandler"]=> object(Closure)#14 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["notFoundHandler"]=> object(Closure)#15 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["notAllowedHandler"]=> object(Closure)#16 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["callableResolver"]=> object(Slim\CallableResolver)#40 (1) { ["container":"Slim\CallableResolver":private]=> *RECURSION* } } ["factories":"Pimple\Container":private]=> object(SplObjectStorage)#4 (1) { ["storage":"SplObjectStorage":private]=> array(0) { } } ["protected":"Pimple\Container":private]=> object(SplObjectStorage)#5 (1) { ["storage":"SplObjectStorage":private]=> array(0) { } } ["frozen":"Pimple\Container":private]=> array(7) { ["settings"]=> bool(true) ["router"]=> bool(true) ["response"]=> bool(true) ["environment"]=> bool(true) ["request"]=> bool(true) ["callableResolver"]=> bool(true) ["foundHandler"]=> bool(true) } ["raw":"Pimple\Container":private]=> array(7) { ["settings"]=> object(Closure)#6 (2) { ["static"]=> array(2) { ["userSettings"]=> array(0) { } ["defaultSettings"]=> array(7) { ["httpVersion"]=> string(3) "1.1" ["responseChunkSize"]=> int(4096) ["outputBuffering"]=> string(6) "append" ["determineRouteBeforeAppMiddleware"]=> bool(false) ["displayErrorDetails"]=> bool(false) ["addContentLengthHeader"]=> bool(true) ["routerCacheFile"]=> bool(false) } } ["this"]=> *RECURSION* } ["router"]=> object(Closure)#11 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["response"]=> object(Closure)#10 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["environment"]=> object(Closure)#8 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } ["request"]=> object(Closure)#9 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["callableResolver"]=> object(Closure)#17 (2) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } ["parameter"]=> array(1) { ["$container"]=> string(10) "" } } ["foundHandler"]=> object(Closure)#12 (1) { ["this"]=> object(Slim\DefaultServicesProvider)#7 (0) { } } } ["keys":"Pimple\Container":private]=> array(11) { ["settings"]=> bool(true) ["environment"]=> bool(true) ["request"]=> bool(true) ["response"]=> bool(true) ["router"]=> bool(true) ["foundHandler"]=> bool(true) ["phpErrorHandler"]=> bool(true) ["errorHandler"]=> bool(true) ["notFoundHandler"]=> bool(true) ["notAllowedHandler"]=> bool(true) ["callableResolver"]=> bool(true) } } ["middleware":protected]=> array(0) { } ["pattern":protected]=> string(13) "/hello/{name}" ["stack":protected]=> object(SplStack)#37 (2) { ["flags":"SplDoublyLinkedList":private]=> int(2) ["dllist":"SplDoublyLinkedList":private]=> array(1) { [0]=> *RECURSION* } } ["middlewareLock":protected]=> bool(true) } ["routeInfo"]=> array(4) { [0]=> int(1) [1]=> string(6) "route0" [2]=> array(1) { ["name"]=> string(4) "mama" } ["request"]=> array(2) { [0]=> string(3) "GET" [1]=> string(54) "http://localhost/slimtest/project/index.php/hello/mama" } } ["name"]=> string(4) "mama" } } ["bodyParsed":protected]=> bool(false) ["bodyParsers":protected]=> array(4) { ["application/json"]=> object(Closure)#33 (2) { ["this"]=> object(Slim\Http\Request)#30 (15) { ["method":protected]=> string(3) "GET" ["originalMethod":protected]=> string(3) "GET" ["uri":protected]=> object(Slim\Http\Uri)#28 (9) { ["scheme":protected]=> string(4) "http" ["user":protected]=> string(0) "" ["password":protected]=> string(0) "" ["host":protected]=> string(9) "localhost" ["port":protected]=> int(80) ["basePath":protected]=> string(27) "/slimtest/project/index.php" ["path":protected]=> string(10) "hello/mama" ["query":protected]=> string(0) "" ["fragment":protected]=> string(0) "" } ["requestTarget":protected]=> NULL ["queryParams":protected]=> NULL ["cookies":protected]=> array(0) { } ["serverParams":protected]=> array(33) { ["HTTP_HOST"]=> string(9) "localhost" ["HTTP_CONNECTION"]=> string(10) "keep-alive" ["HTTP_UPGRADE_INSECURE_REQUESTS"]=> string(1) "1" ["HTTP_USER_AGENT"]=> string(123) "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36 OPR/43.0.2442.1144" ["HTTP_ACCEPT"]=> string(74) "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" ["HTTP_DNT"]=> string(1) "1" ["HTTP_ACCEPT_ENCODING"]=> string(23) "gzip, deflate, sdch, br" ["HTTP_ACCEPT_LANGUAGE"]=> string(26) "en-GB,en-US;q=0.8,en;q=0.6" ["PATH"]=> string(60) "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" ["SERVER_SIGNATURE"]=> string(70) "
> Apache/2.4.18 (Ubuntu) Server at localhost Port 80
> " ["SERVER_SOFTWARE"]=> string(22) "Apache/2.4.18 (Ubuntu)" ["SERVER_NAME"]=> string(9) "localhost" ["SERVER_ADDR"]=> string(3) "::1" ["SERVER_PORT"]=> string(2) "80" ["REMOTE_ADDR"]=> string(3) "::1" ["DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["REQUEST_SCHEME"]=> string(4) "http" ["CONTEXT_PREFIX"]=> string(0) "" ["CONTEXT_DOCUMENT_ROOT"]=> string(13) "/var/www/html" ["SERVER_ADMIN"]=> string(19) "webmaster@localhost" ["SCRIPT_FILENAME"]=> string(40) "/var/www/html/slimtest/project/index.php" ["REMOTE_PORT"]=> string(5) "49504" ["GATEWAY_INTERFACE"]=> string(7) "CGI/1.1" ["SERVER_PROTOCOL"]=> string(8) "HTTP/1.1" ["REQUEST_METHOD"]=> string(3) "GET" ["QUERY_STRING"]=> string(0) "" ["REQUEST_URI"]=> string(38) "/slimtest/project/index.php/hello/mama" ["SCRIPT_NAME"]=> string(27) "/slimtest/project/index.php" ["PATH_INFO"]=> string(11) "/hello/mama" ["PATH_TRANSLATED"]=> string(24) "/var/www/html/hello/mama" ["PHP_SELF"]=> string(38) "/slimtest/project/index.php/hello/mama" ["REQUEST_TIME_FLOAT"]=> float(1508438190.321) ["REQUEST_TIME"]=> int(1508438190) } ["attributes":protected]=> object(Slim\Collection)#31 (1) { ["data":protected]=> array(0) { } }