On Aug 18, 2009, at 1:30 AM, dloy wrote:
> I have a PathParam that contains a forward slash(data/fptr11.xls).
> Is there a mechanism for escaping the slash within Jersey? I tried
> URL Encoding (data%2Ffptr11.xls) in firefox- this got no response -
> it appears to repost whatever screen is there. URL Encoding with
> other values than %2F appears to work.
>
> To verify this I put in code to convert a $ to /. So data$fptr11.xls
> AND data%24fptr11.xls both work properly so the URL Encoding does
> seem to work for other characters.
>
What Web container are you using?
I suspect that the Web container is not correctly managed %2F and the
value is getting decoded before it reaches Jersey and then matching
will fail and return a 404 response.
You can verify if this is the case by adding request/response logging
to the server side:
https://jersey.dev.java.net/nonav/apidocs/1.1.1-ea/jersey/com/sun/jersey/api/container/filter/LoggingFilter.html
Paul.
> Any ideas?
> Thanks
> David
>
> Example URL:
> http://localhost:28080/jstore/fileState/15/12345-abcde/2/data%2ffptr11.xls
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>