public static function encodeRelativeUrl($url)
    {
        $url = str_replace(DIRECTORY_SEPARATOR, '/', $url);
        $parts = explode('/', $url);
        foreach (array_keys($parts) as $key) {
            $parts[$key] = rawurlencode($parts[$key]);
        }
        return implode('/', $parts);
    }
public static function encodeRelativeUrl($url)
    {
        $url = str_replace(DIRECTORY_SEPARATOR, '/', $url);
        $parts = explode('/', $url);
        foreach (array_keys($parts) as $key) {
            $parts[$key] = rawurlencode($parts[$key]);
        }
        return implode('/', $parts);
    }
public static function encodeRelativeUrl ( $ url ) { $ url = str_replace ( DIRECTORY_SEPARATOR , '/' , $ url ) ; $ parts = explode ( '/' , $ url ) ; foreach ( array_keys ( $ parts ) as $ key ) { $ parts [ $ key ] = rawurlencode ( $ parts [ $ key ] ) ; } return implode ( '/' , $ parts ) ; }
encode a relative URL

@access public
@param  string uri
@param  boolean dotMode
@return string
encode a relative URL