Hi, 
I'm using HttpClient 2.o to connect to the following site:
 
<http://www.aeromexico.com:9090/ClubPremier/Saldo/0,11100,11000.html?lang=0&;
location=0&ncuenta=0&reqForm=1&num_socio=767871601&continuar.x=51&continuar.
y=12>
 the hyperlink works fine when using a browser. But when using my code i'm
always getting a 503 HTTP status code, instead of the 200 for ok. and
consecuently i´m not getting any HTML. 
the code is something like this (i'm using a proxy): 
url =
"http://www.aeromexico.com:9090/ClubPremier/Saldo/0,11100,11000.html?lang=0&;
location=0&ncuenta=0&reqForm=1&num_socio=447739905&continuar.x=51&continuar.
y=12";
HttpClient client = new HttpClient(); 
client.getState().setProxyCredentials(null, null, new
UsernamePasswordCredentials(System.getProperty("http.proxyUserName"),
System.getProperty("http.proxyPassword"))); 
client.getHostConfiguration().setProxy(System.getProperty("http.proxyHost"),
Integer.parseInt(System.getProperty("http.proxyPort","80"))); 
GetMethod method1 = new GetMethod(url); 
try{ 
        statusCode = client.executeMethod(method1); 
        System.out.println("Return Code=> " + statusCode); //here i get
always 503 
}catch (HttpRecoverableException e) { 
        System.out.println("An recoverable exception occurred,retrying. " +
e.getMessage());
         e.printStackTrace(); 
}finally{ 
        System.out.println("Releasing Connection method 1....." ); 
        method1.releaseConnection();
 } 

thanks in advance 

Saludos, Arturo 



Reply via email to