I'm trying to execute a basic GET command, but keep getting a 302 
SC_MOVED_TEMPORARILY  error. I can access the URL via my browser and it 
responds. I know that the code below is not accessing the servlet because 
the servlet is not logging any connection.

Can anyone identify a problem with my code below?
Can anyone send me some basic HttpClient usage examples?

Here's my code:

URL url = new URL("http://kbaynes.renex.com:8080/swm/manager";);

// set up the connection
HttpConnection con = new HttpConnection(url.getHost(),url.getPort(),false);
con.open();

HttpState state = new HttpState();
GetMethod get   = new GetMethod();
retVal = get.execute(state,con);

___________________________________________________________
Sent by ePrompter, the premier email notification software.
Free download at http://www.ePrompter.com.

_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to