public function resolveUriPath()
    {
        if(!$this->server)
            return;

        list($requestUri) = explode('?', $this->server['REQUEST_URI']);

        if(strpos($requestUri, $this->server['SCRIPT_NAME']) === 0)
        {
            $basePath = $this->server['SCRIPT_NAME'];
        }
        else
        {
            $basePath = explode('/', $this->server['SCRIPT_NAME']);
            array_pop($basePath);
            $basePath = implode('/', $basePath);
        }

        $requestUri = trim($requestUri, '/');

        $requestUri = '/'.trim(substr($requestUri, strlen(trim($basePath, '/'))), '/');

        $this->uri->setPath($requestUri);
    }
public function resolveUriPath()
    {
        if(!$this->server)
            return;

        list($requestUri) = explode('?', $this->server['REQUEST_URI']);

        if(strpos($requestUri, $this->server['SCRIPT_NAME']) === 0)
        {
            $basePath = $this->server['SCRIPT_NAME'];
        }
        else
        {
            $basePath = explode('/', $this->server['SCRIPT_NAME']);
            array_pop($basePath);
            $basePath = implode('/', $basePath);
        }

        $requestUri = trim($requestUri, '/');

        $requestUri = '/'.trim(substr($requestUri, strlen(trim($basePath, '/'))), '/');

        $this->uri->setPath($requestUri);
    }
public function resolveUriPath ( ) { if ( ! $ this -> server ) return ; list ( $ requestUri ) = explode ( '?' , $ this -> server [ 'REQUEST_URI' ] ) ; if ( strpos ( $ requestUri , $ this -> server [ 'SCRIPT_NAME' ] ) === 0 ) { $ basePath = $ this -> server [ 'SCRIPT_NAME' ] ; } else { $ basePath = explode ( '/' , $ this -> server [ 'SCRIPT_NAME' ] ) ; array_pop ( $ basePath ) ; $ basePath = implode ( '/' , $ basePath ) ; } $ requestUri = trim ( $ requestUri , '/' ) ; $ requestUri = '/' . trim ( substr ( $ requestUri , strlen ( trim ( $ basePath , '/' ) ) ) , '/' ) ; $ this -> uri -> setPath ( $ requestUri ) ; }
Apache only functionality, to resolve uri to current folder the apps is located
@return null
Apache only functionality to resolve uri to current folder the apps is located