big-moving.ru/api/php/protokol.php

15 lines
376 B
PHP
Executable File

if (isset($_SERVER['HTTPS']))
$scheme = $_SERVER['HTTPS'];
else
$scheme = '';
if (($scheme) && ($scheme != 'off')) $scheme = 'https';
else $scheme = 'http';
/*
if ((isset($_SERVER['REQUEST_SCHEME']) AND $_SERVER['REQUEST_SCHEME'] === 'https') OR (isset($_SERVER['HTTPS']) AND $_SERVER['HTTPS'] === 'on'))
$protocol = 'https';
else
$protocol = 'http';
*/