public static function getHostFromUrl($url)
    {
        $parsedUrl = parse_url($url);

        if (empty($parsedUrl['host'])) {
            return;
        }

        return Common::mb_strtolower($parsedUrl['host']);
    }
public static function getHostFromUrl($url)
    {
        $parsedUrl = parse_url($url);

        if (empty($parsedUrl['host'])) {
            return;
        }

        return Common::mb_strtolower($parsedUrl['host']);
    }
public static function getHostFromUrl ( $ url ) { $ parsedUrl = parse_url ( $ url ) ; if ( empty ( $ parsedUrl [ 'host' ] ) ) { return ; } return Common :: mb_strtolower ( $ parsedUrl [ 'host' ] ) ; }
Returns the host part of any valid URL.

@param string $url  Any fully qualified URL
@return string|null The actual host in lower case or null if $url is not a valid fully qualified URL.
Returns the host part of any valid URL .