[Opensource] Question for any of you Servlet API Spec Gurus
Michael Rimov
rimovm at centercomp.com
Thu Oct 3 01:41:40 PDT 2002
Hey All,
I came across a very strange issue with exImageTag() tag that has to do
with the servlet spec. I'm using Tomcat 4.0.4 in development. The code in
question is:
tmp = src();
if (tmp != null) {
results.append(" src=\"");
results.append(response.encodeURL(tmp));
^^^^^^^^^^^^^^^^^^^^^^^^^^
results.append("\"");
}
The problem was that if I went to this page from an HTTP POST event,
everything went well, but if I went there from an HTTP GET event,
encodeURL() would throw an IllegalArgumentException.
[The URL in question was something like "../images/myimage.gif")
Now, if I remove encodeURL() everything works great... but if we have a
dynamic src for the images, removing encodeURL will break that, correct?
Any suggestions as to what would be best for this situation would be
greatly appreciated.
-Mike
More information about the Opensource
mailing list