Possible Duplicate:
How To Find Out If You are Using HTTPS Without $_SERVER['HTTPS']
PHP Get Site URL Protocol - http vs https
How i can get the protocol in php?
$_SERVER['SERVER_PROTOCOL']
shows me the HTTP/1.1 but is there is any way to just echo http or https?