if ($_SERVER['HTTP_X_FORWARDED_PROTO'] === 'https' || $_SERVER['HTTP_CF_VISITOR'] === '{"scheme":"https"}') { $_SERVER['HTTPS'] = 'on'; }