Checks whether an HTTPS request is being served.
bool TRUE if the request is HTTPS, FALSE otherwise.
function drupal_is_https() { return isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on'; }