Yep,

you can do something like so:

                URL url = new URL(hostname);

                HttpURLConnection conn =
(HttpURLConnection)url.openConnection();
                conn.setDoOutput(true);
                conn.setRequestMethod("POST");
                PrintWriter stream = new
PrintWriter(conn.getOutputStream(), true);
                stream.println("xml=" + URLEncoder.encode(xml));

Regards,

Damian

> HI!
> 
> I need to make a servlet (or JSP page) to get an external page using the
> method POST. Is it possible with the URLConnection class?
> 
> Thanks.
> Guilherme Ceschiatti

Reply via email to