That URL needs to be encoded. Either wrap it in some method that will
encode it, i.e. response.encodeURL(myURL). If you're coming from a static
page and can't do that, the standard escape for a space is %20, so you could
rewrite your URL as http://webserver/servlets/test?John%20Chuck
-- Kyal
----------------------------------------------------
Kyallee Dalrymple [EMAIL PROTECTED]
Software Engineer (303)-277-1997 x108
Polygon Network, Inc. http://www.polygon.net/
----------------------------------------------------
-----Original Message-----
From: A mailing list for discussion about Sun Microsystem's Java Servlet
API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of
Thomas To
Sent: Monday, May 10, 1999 12:35 PM
To: [EMAIL PROTECTED]
Subject: question on getParameter()
Hi all,
I have a question regarding HttpServletRequest.getParameter().
In the servlet, i'm calling getParameter() to get the value that is
passed to the servlet through the following HTML statement:
<a href="http://webserver/servlets/test?John Chuck">
getParameter() starts reading the string after the ? and stops at the
space between John and Chuck. If I removed the space, it will read all
the way to the double quote. Is there any way I can pass any string
that contains space in between so that getParameter() will read all the
way until the double quote?
Thanks for your help.
- Thomas -
___________________________________________________________________________
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
___________________________________________________________________________
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