Skip to content

Commit a77f19b

Browse files
authored
Merge pull request #85 from joanhey/symfony-7.4
Symfony 7.4
2 parents 462704b + f5e0385 commit a77f19b

File tree

10 files changed

+34
-21
lines changed

10 files changed

+34
-21
lines changed

config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,6 @@ silex-2.3
3232
slim-4.14
3333
symfony-5.4
3434
symfony-6.4
35-
symfony-7.0
35+
symfony-7.4
3636
yii-2.0-basic
3737
"

symfony-7.0/_benchmark/symfony/public/index.php

Lines changed: 0 additions & 19 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.
File renamed without changes.

symfony-7.0/_benchmark/setup.sh renamed to symfony-7.4/_benchmark/setup.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/sh
22
# create project
33
rm -rf _benchmark/temp
4-
composer create-project symfony/skeleton:7.0.* ./_benchmark/temp --ansi
4+
composer create-project symfony/skeleton:7.4.* ./_benchmark/temp --ansi
55
mv ./_benchmark/temp/{.,}* ./
66

77
# have the route & controller
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
<?php
2+
3+
use App\Kernel;
4+
use Symfony\Component\Dotenv\Dotenv;
5+
use Symfony\Component\ErrorHandler\Debug;
6+
use Symfony\Component\HttpFoundation\Request;
7+
8+
require dirname(__DIR__).'/vendor/autoload.php';
9+
10+
(new Dotenv())->bootEnv(dirname(__DIR__).'/.env');
11+
12+
if ($_SERVER['APP_DEBUG']) {
13+
umask(0000);
14+
15+
Debug::enable();
16+
}
17+
18+
if ($trustedProxies = $_SERVER['TRUSTED_PROXIES'] ?? false) {
19+
Request::setTrustedProxies(explode(',', $trustedProxies), Request::HEADER_X_FORWARDED_ALL ^ Request::HEADER_X_FORWARDED_HOST);
20+
}
21+
22+
if ($trustedHosts = $_SERVER['TRUSTED_HOSTS'] ?? false) {
23+
Request::setTrustedHosts([$trustedHosts]);
24+
}
25+
26+
$kernel = new Kernel($_SERVER['APP_ENV'], (bool) $_SERVER['APP_DEBUG']);
27+
$request = Request::createFromGlobals();
28+
$response = $kernel->handle($request);
29+
$response->send();
30+
$kernel->terminate($request, $response);
31+
32+
require $_SERVER['DOCUMENT_ROOT'].'/PHP-Frameworks-Bench/libs/output_data.php';
File renamed without changes.

0 commit comments

Comments
 (0)