It's not a secret anymore!
The moose likes JSP and the fly likes URL arguments Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "URL arguments" Watch "URL arguments" New topic

URL arguments

Joshi Thomas

Joined: Oct 03, 2002
Posts: 7
I am trying to pass a URL as argument to another jsp page, unfortunately the URL (argument) also contains an argument and I cannot get the value of the URL.
eg: test.jsp?
I want the value of url to be "" but when I do a request.getparameter("url"), I am getting null for the url.
Thanks in advance.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63852

You need to encode the URL that you use as a request parameter argument so that it doesn't confuse the URL parsers.
Check out the and classes.

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: URL arguments
It's not a secret anymore!