bloody error
PHP : get Request protocol Http or HTTPS
How to get Requested protocol Http or HTTPS in PHP?
This function will return True if HTTPS when called…
is_https()
{
return strtolower(substr($_SERVER["SERVER_PROTOCOL"],0,5))==’https’? true : false;
}
is_https()
{
return strtolower(substr($_SERVER["SERVER_PROTOCOL"],0,5))=='https'? true : false;
}
3 Responses to PHP : get Request protocol Http or HTTPS
Leave a Reply Cancel reply
Recent Comments
- Charles on Object doesn’t support this property or method
- Lucas on PHP : get Request protocol Http or HTTPS
- Chris on Split & Concat Snow Leopard Error : (-2753) The variable thePanel is not defined
- Get url with protocol, http or https – Richard Choi on PHP : get Request protocol Http or HTTPS
- daGrevis on PHP : get Request protocol Http or HTTPS








Thanks. )
[...] http://www.bloodyerror.com/2009/09/php-get-request-protocol-http-or-https/ [...]
what about $_SERVER['HTTPS'] ?