You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by bu...@apache.org on 2003/03/26 23:39:31 UTC
DO NOT REPLY [Bug 18301] -
Fixed deprecation warning for URLEncoder.encode(String) method.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18301>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=18301
Fixed deprecation warning for URLEncoder.encode(String) method.
dlr@apache.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Severity|Normal |Minor
Target Milestone|--- |1.4
------- Additional Comments From dlr@apache.org 2003-03-26 22:39 -------
Attila Szegedi <sz...@freemail.hu> wrote:
You are fully aware that URLEncoder.encode(String, String) exists only under
JDK 1.4, are you? (Also, URLEncoder.encode(String) is only deprecated from
there upwards...)
If you want your code to have charset-sensitive URL encoding and still
remain compatible with JDK < 1.4, you need to use a hack like
URLEncoder.encode(new String(url.getBytes(encoding)))
Naturally, this approach is fragile in case your platform default encoding
is something exotic, altough it works fine with ISO-8859-x encodings being
default encodings for the platform.
Tim Colson responded:
No, I wasn't aware.
Thanks for pointing that out Atilla, please disregard the patch. :-(
Tim, Attila, should this issue be closed? If so, does a resolution of INVALID
make sense?
---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-dev-help@jakarta.apache.org