function is_https() {
if (!empty($_server['https']) &&strtolower($_server['https'])!== 'off') {
return true;
} elseif ( isset($_server['http_x_forwarded_proto']) &&$_server['http_x_forwarded_proto'] === 'https') {
return true;
} elseif (!empty($_server['http_front_end_https']) &&strtolower($_server['http_front_end_https'])!== 'off') {
return true;
}else{
return false;
}
}
- 编程问答
- 答案列表
php获取当前网页地址[朗读]
加入收藏