diff options
| -rw-r--r-- | public/index.php | 2 | ||||
| -rw-r--r-- | src/Config.php | 2 | ||||
| -rw-r--r-- | src/controller/URL.php | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/public/index.php b/public/index.php index 37ebaf0..3c6f261 100644 --- a/public/index.php +++ b/public/index.php | |||
| @@ -26,7 +26,7 @@ require '../src/model/doctrine-bootstrap.php'; // isDevMode est sur "true", DSN | |||
| 26 | 26 | ||
| 27 | URL::setProtocol(Config::$protocol); // utile si port autre que 80 ou 443 | 27 | URL::setProtocol(Config::$protocol); // utile si port autre que 80 ou 443 |
| 28 | URL::setPort(Config::$port); | 28 | URL::setPort(Config::$port); |
| 29 | URL::setHost(Config::$host); | 29 | URL::setHost($_SERVER['HTTP_HOST']); |
| 30 | 30 | ||
| 31 | //require('controller/Session.php'); | 31 | //require('controller/Session.php'); |
| 32 | ini_set('session.cookie_samesite', 'Strict'); | 32 | ini_set('session.cookie_samesite', 'Strict'); |
diff --git a/src/Config.php b/src/Config.php index cfec876..882ec98 100644 --- a/src/Config.php +++ b/src/Config.php | |||
| @@ -15,7 +15,7 @@ class Config | |||
| 15 | 15 | ||
| 16 | // classe URL | 16 | // classe URL |
| 17 | static public string $protocol = 'http'; | 17 | static public string $protocol = 'http'; |
| 18 | static public string $host = 'nageurs.localhost'; | 18 | //static public string $host = ''; |
| 19 | static public string $port = '80'; | 19 | static public string $port = '80'; |
| 20 | 20 | ||
| 21 | // copier dans ce tableau les variables contenant des chemins | 21 | // copier dans ce tableau les variables contenant des chemins |
diff --git a/src/controller/URL.php b/src/controller/URL.php index 956d85d..3ebc488 100644 --- a/src/controller/URL.php +++ b/src/controller/URL.php | |||
| @@ -6,7 +6,7 @@ declare(strict_types=1); | |||
| 6 | class URL implements Stringable | 6 | class URL implements Stringable |
| 7 | { | 7 | { |
| 8 | static private string $protocol = 'http://'; | 8 | static private string $protocol = 'http://'; |
| 9 | static private string $host = 'localhost'; | 9 | static private string $host = ''; |
| 10 | static private string $port; | 10 | static private string $port; |
| 11 | static private string $path = '/index.php'; | 11 | static private string $path = '/index.php'; |
| 12 | private array $params; | 12 | private array $params; |
