Hi
We are using Websphere 5.1 and developing on WSAD 5.1.2.
We are trying to do a http post with the httpclient to a partner side.
when executing the connection the server says:
Servlet Request Processor Exception: Virtual Host/WebGroup Not Found : The
web group /wli/dede/entry/welcome.php has not been defined
see code below:
public void doGet(HttpServletRequest request, HttpServletResponse
response) throws ServletException, IOException {
try {
System.setProperty(
"org.apache.commons.logging.Log",
"org.apache.commons.logging.impl.SimpleLog");
System.setProperty(
"org.apache.commons.logging.simplelog.showdatetime", "true");
System.setProperty(
"org.apache.commons.logging.simplelog.log.httpclient.wire", "debug");
System.setProperty(
"org.apache.commons.logging.simplelog.log.org.apache.commons.httpclient",
"debug");
PostMethod post = new PostMethod(
"http://wli-de.eurotax.com/wli/dede/entry/welcome.php");
NameValuePair[] data = { new NameValuePair("1",
"a"), new NameValuePair("2", "b"), new NameValuePair("3", "c")};
post.setRequestBody(data);
HttpClient l_client = new HttpClient();
l_client.executeMethod(post);
InputStream l_input =
post.getResponseBodyAsStream();
int l_readByte = l_input.read();
while (l_readByte != -1) {
response.getWriter().write(l_readByte);
l_readByte = l_input.read();
}
post.releaseConnection();
}
catch (Exception e) {
e.printStackTrace();
}
}
Does anyone have a idea of what we are doing wrong? for example if we use
www.web.de as url, it works fine.
__
Matthias Stoll
hpi GmbH
Application Development
Am Limes Park 2
D - 65843 Sulzbach/Ts.
Web site: http://www.hpigmbh.com