aspose file tools*
The moose likes Servlets and the fly likes How to emulate a HTML Form Submission with a servelt? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "How to emulate a HTML Form Submission with a servelt?" Watch "How to emulate a HTML Form Submission with a servelt?" New topic
Author

How to emulate a HTML Form Submission with a servelt?

Gregory Cranz
Greenhorn

Joined: Sep 09, 2002
Posts: 9
<p>I am using a search/indexing software package which has limited functionality in that it will only produce output from a form submission.</p>
<p>My thought is to create a servlet 'wrapper' which would provide an interafce so that I could call to the URL of the servlet, and provide it a search string as a parameter. The servlet would then perform the form submission and send the user to the resulting page. This is similar to page forwarding, but with more involved.</p>
<p>My question is, is this even possible & if so, then How?</p>


Never Underestimate the Power of What Works!
Malhar Barai
Author
Ranch Hand

Joined: Aug 17, 2001
Posts: 399
hi greg
Welcome to JavaRanch..
can u elaborate your query a bit more...
till what i understood...u can always imitate actions performed by HTML in servlets i.e just code the HTML in servlet & u can make the form work in the same way as it does in th HTML format...
but to be bang on target i need more info...
hope this helps
malhar
Gregory Cranz
Greenhorn

Joined: Sep 09, 2002
Posts: 9
I will elaborate:
I am attempting to use the Hummingbird Search Server (formerly known as Fulcrum) - and the caveat is that to get a response I need to complete a form submission. This apparently needs to be a POST operation, otherwise I would simply encode the parameters in the URL.
What I want to do is to write a servlet that takes a single parameter, performs a form submission including all of the hidden parameters and then forwards the user to the resulting page.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to emulate a HTML Form Submission with a servelt?