aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes URL Rewriting for HTML form's submission? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "URL Rewriting for HTML form Watch "URL Rewriting for HTML form New topic
Author

URL Rewriting for HTML form's submission?

Anand Wadhwani
Ranch Hand

Joined: Mar 21, 2005
Posts: 151
While generating <A href="..."> in a servlet response, we can use response.encodeURL() to append session id to the URL. But what should we do for URL rewriting/encoding while submitting an html form (GET/POST) where target url is specified in form's action? Should this be done manually by appending session id in form's action url using getId() method of HttpSession ?

Please advise. Thanks!
[ April 24, 2005: Message edited by: Anand Wadhwani ]

SCWCD 1.4<br />---------------------<br />Ability is what you're capable of. <br />Motivation determines what you do. <br />Attitude determines how well you do it.<br />---------------------
Debashish Chakrabarty
Ranch Hand

Joined: May 14, 2002
Posts: 230

A question that struck me too while ago. Yes, you should encode the URL even when doing a form submission. See below:

Hope this helps


Debashish
SCJP2, SCWCD 1.4, PMP, ITIL Foundation
Anand Wadhwani
Ranch Hand

Joined: Mar 21, 2005
Posts: 151
Thanks Debashish, that helps!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: URL Rewriting for HTML form's submission?