sonjavanteese
8/24/2019 - 12:20 PM

If HTTP/HTTPS

If HTTP/HTTPS

if (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443) {

// HTTPS

} else {

// HTTP

}