Skip to content

Sub-optimal result in relativeTo with fragment #95

Closed
psranga opened this Issue Jun 21, 2013 · 3 comments

3 participants

@psranga
psranga commented Jun 21, 2013

URI("http://www.example.com:8080/dir/file#abcd").relativeTo('http://www.example.com:8080/dir/file').toString()

returns

./file#abcd ('#abcd' would have been better)

The more-optimal result seems to work with absoluteTo:

URI("#abcd").absoluteTo('http://www.example.com:8080/dir/file').toString()

returns

"http://www.example.com:8080/dir/file#abcd"

Great library, btw!

@rodneyrehm
Medialize member

Maybe @djcsdy has some ideas, he already did some sweet fixing in #78

@djcsdy
djcsdy commented Jul 1, 2013

I agree with @psranga, #abcd would be better. #78 doesn’t fix that yet though, it returns file#abcd.

The query component should get similar relativization treatment also IMO.

I do mean to get back and finish my work for #78 at some point, but my workload has been higher than expected lately and my health has been poor – so it’s not going to happen for a little while unfortunately.

@rodneyrehm
Medialize member

I've fixed this in master - it will be included in the next release. thank you for your help!

@rodneyrehm rodneyrehm closed this Aug 4, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.