Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / September 2006

Tip: Looking for answers? Try searching our database.

servlet request handling - escaped characters in request

Thread view: 
Thea - 15 Sep 2006 14:09 GMT
Hello
I have following problem and I'm not sure where to look for solution,
or even if this is correct group for it, so please redirect me if you
know more apropriate group / know good webpage

I have request coming from outside world. As many requests do, one that
I'm recieving has parameters coming with it.
Trouble is that parameters can come in form
bin.id=45&res.h=150&res.w=150
or
bin.id=45&res.h=150&res.w=150
When parameters are given like in first case everything works fine, but
when second type of request comes, request.getParameterNames(),
request.getParameter(...) and all functions that deal with parameters
simply do not see them.
I guess that's because of those escaped ampersand signs, but have
absolutely no idea how to solve this problem... Is there maybe any way
to get around it?
I cannot avoid getting requests with escaped ampersands and they must
be processed properly, I can't simply send error response.

I really have no idea where to start searching...
Thanks for help. :)
~Thea
steepyirl - 15 Sep 2006 16:15 GMT
Try java.net.URLDecoder.decode(), *before* you append the params to the
request URI.

> Hello
> I have following problem and I'm not sure where to look for solution,
[quoted text clipped - 20 lines]
> Thanks for help. :)
> ~Thea
Thea - 22 Sep 2006 13:08 GMT


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.