public static function getSelfURL()
    {
        $selfURLhost = self::getSelfURLhost();

        $requestURI = '';
        if (!empty($_SERVER['REQUEST_URI'])) {
            $requestURI = $_SERVER['REQUEST_URI'];
            if ($requestURI[0] !== '/') {
                if (preg_match('#^https?://[^/]*(/.*)#i', $requestURI, $matches)) {
                    $requestURI = $matches[1];
                }
            }
        }

        $infoWithBaseURLPath = self::buildWithBaseURLPath($requestURI);
        if (!empty($infoWithBaseURLPath)) {
            $requestURI = $infoWithBaseURLPath;
        }

        return $selfURLhost . $requestURI;
    }
public static function getSelfURL()
    {
        $selfURLhost = self::getSelfURLhost();

        $requestURI = '';
        if (!empty($_SERVER['REQUEST_URI'])) {
            $requestURI = $_SERVER['REQUEST_URI'];
            if ($requestURI[0] !== '/') {
                if (preg_match('#^https?://[^/]*(/.*)#i', $requestURI, $matches)) {
                    $requestURI = $matches[1];
                }
            }
        }

        $infoWithBaseURLPath = self::buildWithBaseURLPath($requestURI);
        if (!empty($infoWithBaseURLPath)) {
            $requestURI = $infoWithBaseURLPath;
        }

        return $selfURLhost . $requestURI;
    }
public static function getSelfURL ( ) { $ selfURLhost = self :: getSelfURLhost ( ) ; $ requestURI = '' ; if ( ! empty ( $ _SERVER [ 'REQUEST_URI' ] ) ) { $ requestURI = $ _SERVER [ 'REQUEST_URI' ] ; if ( $ requestURI [ 0 ] !== '/' ) { if ( preg_match ( '#^https?://[^/]*(/.*)#i' , $ requestURI , $ matches ) ) { $ requestURI = $ matches [ 1 ] ; } } } $ infoWithBaseURLPath = self :: buildWithBaseURLPath ( $ requestURI ) ; if ( ! empty ( $ infoWithBaseURLPath ) ) { $ requestURI = $ infoWithBaseURLPath ; } return $ selfURLhost . $ requestURI ; }
Returns the URL of the current host + current view + query.

@return string
Returns the URL of the current host + current view + query .