* @param Exception $e * @return void */ protected function handleRoutingException(\Exception $e) { if ($e instanceof ResourceNotFoundException) { throw new NotFoundHttpException($e->getMessage()); }
} // The Symfony routing component's exceptions implement this interface we // can type-hint it to make sure we're only providing special handling // for those exceptions, and not other random exceptions that occur. catch (ExceptionInterface $e) { $this->handleRoutingException($e); }
} // Once we have the route, we can just run it to get the responses, which will // always be instances of the Response class. Once we have the responses we // will execute the global "after" middlewares to finish off the request. else { $this->currentRoute = $route = $this->findRoute($request); $response = $route->run($request);
if ($this->isDownForMaintenance()) { $response = $this['events']->until('illuminate.app.down'); if ( ! is_null($response)) return $this->prepareResponse($response, $request); } return $this['router']->dispatch($this->prepareRequest($request)); }
/** * Handles the given request and delivers the response. * * @return void */ public function run() { $response = $this->dispatch($this['request']); $this['router']->callCloseFilter($this['request'], $response);
| Once we have the application, we can simply call the run method, | which will execute the request and send the response back to | the client's browser allowing them to enjoy the creative | and wonderful applications we have created for them. | */ $app->run(); /*
Key | Value |
USER | salahelmbf |
FCGI_ROLE | RESPONDER |
REDIRECT_STATUS | 200 |
UNIQUE_ID | ZgYFEpA@QuV0kFLmsy7QugAAABM |
GEOIP_COUNTRY_CODE | US |
GEOIP_COUNTRY_NAME | United States |
GEOIP_REGION | VA |
GEOIP_CITY | Ashburn |
GEOIP_DMA_CODE | 511 |
GEOIP_AREA_CODE | 703 |
GEOIP_LATITUDE | 39.046902 |
GEOIP_LONGITUDE | -77.490303 |
SCRIPT_URL | /uploads/solfeggio/M023.jpg |
SCRIPT_URI | http://salahelmahdi.com/uploads/solfeggio/M023.jpg |
CFG_CLUSTER | cluster005 |
ENVIRONMENT | production |
HTTP_HOST | salahelmahdi.com |
HTTP_X_PREDICTOR | 1 |
HTTP_X_FORWARDED_FOR | 3.236.214.123 |
HTTP_X_FORWARDED_PROTO | http |
HTTP_X_OVHREQUEST_ID | c7b4be862dc9efd3e7fbb44483fd33ac |
HTTP_ACCEPT | */* |
HTTP_USER_AGENT | claudebot |
HTTP_X_FORWARDED_PORT | 80 |
HTTP_X_REMOTE_PORT | 53270 |
HTTP_X_REMOTE_IP | 3.236.214.123 |
HTTP_X_REMOTE_PROTO | http |
HTTP_FORWARDED | for=3.236.214.123; proto=http; host=salahelmahdi.com |
HTTP_REMOTE_PORT | 53270 |
HTTP_X_IPLB_UNIQUE_ID | 03ECD67B:D016_D5BA2110:0050_66060512_42072:1AE9 |
HTTP_REMOTE_IP | 3.236.214.123 |
SERVER_SIGNATURE | |
SERVER_SOFTWARE | Apache |
SERVER_NAME | salahelmahdi.com |
SERVER_ADDR | 10.5.20.98 |
SERVER_PORT | 80 |
REMOTE_ADDR | 3.236.214.123 |
DOCUMENT_ROOT | /home/salahelmbf/www/public |
SERVER_ADMIN | postmaster@salahelmahdi.com |
SCRIPT_FILENAME | /home/salahelmbf/www/public/index.php |
REMOTE_PORT | 50246 |
REDIRECT_URL | /uploads/solfeggio/M023.jpg |
GATEWAY_INTERFACE | CGI/1.1 |
SERVER_PROTOCOL | HTTP/1.1 |
REQUEST_METHOD | GET |
QUERY_STRING | |
REQUEST_URI | /uploads/solfeggio/M023.jpg |
SCRIPT_NAME | /index.php |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1711670546.1423 |
REQUEST_TIME | 1711670546 |
argv | Array ( ) |
argc | 0 |
Key | Value |
_sf2_attributes | Array ( [_token] => 2658gLjtUy07PHNPOssZcZvGDsZNphFE34uAXb2Y ) |
_sf2_flashes | Array ( ) |
_sf2_meta | Array ( [u] => 1711670546 [c] => 1711670546 [l] => 7200 ) |
Key | Value |
USER | salahelmbf |
FCGI_ROLE | RESPONDER |
REDIRECT_STATUS | 200 |
UNIQUE_ID | ZgYFEpA@QuV0kFLmsy7QugAAABM |
GEOIP_COUNTRY_CODE | US |
GEOIP_COUNTRY_NAME | United States |
GEOIP_REGION | VA |
GEOIP_CITY | Ashburn |
GEOIP_DMA_CODE | 511 |
GEOIP_AREA_CODE | 703 |
GEOIP_LATITUDE | 39.046902 |
GEOIP_LONGITUDE | -77.490303 |
SCRIPT_URL | /uploads/solfeggio/M023.jpg |
SCRIPT_URI | http://salahelmahdi.com/uploads/solfeggio/M023.jpg |
CFG_CLUSTER | cluster005 |
ENVIRONMENT | production |
HTTP_HOST | salahelmahdi.com |
HTTP_X_PREDICTOR | 1 |
HTTP_X_FORWARDED_FOR | 3.236.214.123 |
HTTP_X_FORWARDED_PROTO | http |
HTTP_X_OVHREQUEST_ID | c7b4be862dc9efd3e7fbb44483fd33ac |
HTTP_ACCEPT | */* |
HTTP_USER_AGENT | claudebot |
HTTP_X_FORWARDED_PORT | 80 |
HTTP_X_REMOTE_PORT | 53270 |
HTTP_X_REMOTE_IP | 3.236.214.123 |
HTTP_X_REMOTE_PROTO | http |
HTTP_FORWARDED | for=3.236.214.123; proto=http; host=salahelmahdi.com |
HTTP_REMOTE_PORT | 53270 |
HTTP_X_IPLB_UNIQUE_ID | 03ECD67B:D016_D5BA2110:0050_66060512_42072:1AE9 |
HTTP_REMOTE_IP | 3.236.214.123 |
SERVER_SIGNATURE | |
SERVER_SOFTWARE | Apache |
SERVER_NAME | salahelmahdi.com |
SERVER_ADDR | 10.5.20.98 |
SERVER_PORT | 80 |
REMOTE_ADDR | 3.236.214.123 |
DOCUMENT_ROOT | /home/salahelmbf/www/public |
SERVER_ADMIN | postmaster@salahelmahdi.com |
SCRIPT_FILENAME | /home/salahelmbf/www/public/index.php |
REMOTE_PORT | 50246 |
REDIRECT_URL | /uploads/solfeggio/M023.jpg |
GATEWAY_INTERFACE | CGI/1.1 |
SERVER_PROTOCOL | HTTP/1.1 |
REQUEST_METHOD | GET |
QUERY_STRING | |
REQUEST_URI | /uploads/solfeggio/M023.jpg |
SCRIPT_NAME | /index.php |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1711670546.1423 |
REQUEST_TIME | 1711670546 |
argv | Array ( ) |
argc | 0 |