On Tue, 5 Feb 2002, Margaret Fisk wrote:

> + is a character used in directions for http and so is probably
> being interpreted rather than read.
>
> The html conversion for + is + You have to translate C++ into
> C++ to use it on the line, just as you converted the space
> to %20.
>
> There are several conversion tables out there. Here's the one I used.
> http://www.bbsinc.com/symbol.html

I don't think it needs to be that complicated, I think you can just
call java.net.URLEncoder.encode to encode the string in question.  If
you're going to have potentially problematic characters in parameter
values (e.g. non alpha-numeric characters), it might be a good idea to
call this method on them before putting them in the URL.  (Note: You
may be able to get away with passing the whole query string -- without
the '?' -- to this method, but really it should only need to be done
on the values, not the names/keys.)


> -----Original Message-----
> From: Rajeshwar Rao V [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 05, 2002 11:32 AM
> To: [EMAIL PROTECTED]
> Subject: ++ sign in the request parameter.
>
> Hi All,
>
> If I have this
> "http://localhost:8080/zeborg/skillList.do?skillId=5&skillName=C++%20Prog.>"
> in my browser URL and when I try to get skillName by using
> request.getParameter("skillName"),I am getting only the value as 'C' not
> 'C++',,can anybody tell me what's the problem and what's the solution.
>

Milt Epstein
Research Programmer
Software/Systems Development Group
Computing and Communications Services Office (CCSO)
University of Illinois at Urbana-Champaign (UIUC)
[EMAIL PROTECTED]

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to