# HTML sent by doPost



## ZheCk7 (5. Mrz 2007)

I have a servlet doing this:

```
<form action="ACTION URL" method="post">
    <input type="text" name="id" style="width: 100%"></td>
    <input type="password" name="password" style="width: 100%"></td>
    <input type="image" src="/submit.gif" class="submitImage">
</form>
```

Indeed I need to do it inside my Java Application:
i mean i don't really need the servlet, if I can send this data from my application. I have basic knowledge about how a normal HTML response page is built, i would like to know if I have to send line by line all the headers and body, and how to include the 2 parameters i need.
Or, if there is some kind of function that can do that without having to manually insert all that stuff.

Thanks
[/code]


----------



## m@nu (6. Mrz 2007)

i've done something like this once with the httpclient from apache.
:arrow: http://jakarta.apache.org/commons/httpclient/

have a look there for easy tutorials.


----------



## ZheCk7 (7. Mrz 2007)

I found quite a similar way but don't know if my way works...
and anyway your hint sounds WONDERFUL !!!

Many thanks !!!!


----------

