add env.descartes.php.dist
This commit is contained in:
parent
f992fe21bc
commit
78fce650cc
|
@ -0,0 +1,21 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
$http_dir_path = '/raspisms'; //Path we need to put after servername in url to access app
|
||||||
|
$http_protocol = (isset($_SERVER['HTTPS']) ? 'https' : 'http') . '://';
|
||||||
|
$http_server_name = isset($_SERVER['SERVER_NAME']) ? $_SERVER['SERVER_NAME'] : 'localhost';
|
||||||
|
$https = $_SERVER['HTTPS'] ?? false;
|
||||||
|
|
||||||
|
if ( !isset($_SERVER['SERVER_PORT']) || ($_SERVER['SERVER_PORT'] == 80 && !$https) || ($_SERVER['SERVER_PORT'] == 443 && $https) )
|
||||||
|
{
|
||||||
|
$http_server_port = '';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$http_server_port = ':' . $_SERVER['SERVER_PORT'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$http_pwd = $http_protocol . $http_server_name . $http_server_port . $http_dir_path;
|
||||||
|
|
||||||
|
$env = [
|
||||||
|
'HTTP_PWD' => $http_pwd,
|
||||||
|
];
|
Loading…
Reference in New Issue