You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by Web Position Generator <wp...@unrealmarketing.com> on 2003/04/14 21:31:55 UTC

httpclient does not work on this specific site!

Hi,
I am new with httpclient. I just test it and it wroks great.
I tested one of your codes, ClientApp.java, to see how it works, so it was working perfectly. Thank you for the clean examples, [only client.setTimeout(30000); /* milliseconds */  was giving error]

Well my problem is  httpclient does not work with this url http://www.shoemall.com
Actually my java program could not read above url, and that was the main reason I tried to use httpClient. 
But still I faced the same problem with httpClient.

Can you please give it a try, just try to read that page, and see what happens.

I greatly appreciate your help, or any guide for solving my problem.


With Regards,
Navid

Re: httpclient does not work on this specific site!

Posted by Andre John Mas <aj...@newtradetech.com>.
Web Position Generator wrote:
> Hi,
> I am new with httpclient. I just test it and it wroks great.
> I tested one of your codes, ClientApp.java, to see how it works, so it was working perfectly. Thank you for the clean examples, [only client.setTimeout(30000); /* milliseconds */  was giving error]
> 
> Well my problem is  httpclient does not work with this url http://www.shoemall.com
> Actually my java program could not read above url, and that was the main reason I tried to use httpClient. 
> But still I faced the same problem with httpClient.
> 
> Can you please give it a try, just try to read that page, and see what happens.
> 
> I greatly appreciate your help, or any guide for solving my problem.
> 
> 
> With Regards,
> Navid
> 

Are you behind a proxy by any chance and have not configured the
client or browser for the proxy?

Andre


Re: httpclient does not work on this specific site!

Posted by Oleg Kalnichevski <o....@dplanet.ch>.
Navid,

I do not know what I have been doing wrong, but it worked just fine with
;-)

Here's the wire log:

[DEBUG] wire - ->> "GET / HTTP/1.1[\r][\n]"
[DEBUG] wire - ->> "User-Agent: Jakarta
Commons-HttpClient/2.0alpha3[\r][\n]"
[DEBUG] wire - ->> "Host: www.shoemall.com[\r][\n]"
[DEBUG] wire - ->> "[\r][\n]"
[DEBUG] wire - -<< "HTTP/1.1 302 Object moved[\r][\n]"
[DEBUG] wire - -<< "Server: Microsoft-IIS/5.0[\r][\n]"
[DEBUG] wire - -<< "Date: Mon, 14 Apr 2003 20:42:11 GMT[\r][\n]"
[DEBUG] wire - -<< "Pragma: no-cache[\r][\n]"
[DEBUG] wire - -<< "Location:
http://www.shoemall.com/Default.asp?cookie%5Ftest=1[\r][\n]"
[DEBUG] wire - -<< "Content-Length: 172[\r][\n]"
[DEBUG] wire - -<< "Content-Type: text/html;
Charset=Windows-1252[\r][\n]"
[DEBUG] wire - -<< "Expires: Wed, 14 Apr 1993 05:00:00 GMT[\r][\n]"
[DEBUG] wire - -<< "Set-Cookie: MSCS2000TestCookie=1; expires=Tue,
15-Apr-2003 20:42:12 GMT; path=/[\r][\n]"
[DEBUG] wire - -<< "Cache-control: no-cache[\r][\n]"
[DEBUG] wire - -<< "<head><title>Object moved</title></head>[\n]"
[DEBUG] wire - -<< "<body><h1>Object Moved</h1>This object may be found
<a
HREF="http://www.shoemall.com/Default.asp?cookie%5Ftest=1">here</a>.</body>[\n]"
[DEBUG] wire - ->> "GET /Default.asp?cookie%5Ftest=1 HTTP/1.1[\r][\n]"
[DEBUG] wire - ->> "User-Agent: Jakarta
Commons-HttpClient/2.0alpha3[\r][\n]"
[DEBUG] wire - ->> "Host: www.shoemall.com[\r][\n]"
[DEBUG] wire - ->> "Cookie: $Version=0; MSCS2000TestCookie=1;
$Path=/[\r][\n]"
[DEBUG] wire - ->> "[\r][\n]"
[DEBUG] wire - -<< "HTTP/1.1 200 OK[\r][\n]"
[DEBUG] wire - -<< "Server: Microsoft-IIS/5.0[\r][\n]"
[DEBUG] wire - -<< "Date: Mon, 14 Apr 2003 20:42:28 GMT[\r][\n]"
[DEBUG] wire - -<< "Pragma: no-cache[\r][\n]"
[DEBUG] wire - -<< "pragma: no-cache[\r][\n]"
[DEBUG] wire - -<< "Content-Length: 23349[\r][\n]"
[DEBUG] wire - -<< "Content-Type: text/html;
Charset=Windows-1252[\r][\n]"
[DEBUG] wire - -<< "Expires: Wed, 14 Apr 1993 05:00:00 GMT[\r][\n]"
[DEBUG] wire - -<< "Set-Cookie:
MSCSProfile=61E4CECF7275066FD87B9817DA5865CB580D983A3DAD702BCFDAF3D4081B1B5A6BA2C2F6D18ACADAEB1C63A5947B1FE1B8C9DA62886585D772EC2B7D95532AAFFB2253CDB14E674DC58B46F5511A1F63811B489D6691977037314A523DFFBD71450E901B0002FEB66340C591581D5DD13508C86F174A500767924ABF47E15E2F76D9A7E59528BF64; expires=Fri, 15-Jan-2038 06:00:00 GMT; path=/[\r][\n]"
[DEBUG] wire - -<< "Set-Cookie:
UserProfileTimeStamp=4%2F14%2F2003+3%3A42%3A13+PM; path=/[\r][\n]"
[DEBUG] wire - -<< "Set-Cookie: MSCS2000TestCookie=1; expires=Sun,
13-Apr-2003 20:42:12 GMT; path=/[\r][\n]"
[DEBUG] wire - -<< "Cache-control: no-cache[\r][\n]"

What version of HttpClient have you been using? I'd strongly recommend
you upgrading to the latest nightly

http://jakarta.apache.org/commons/httpclient/downloads.html

Cheers

Oleg


On Mon, 2003-04-14 at 21:31, Web Position Generator wrote:
> Hi,
> I am new with httpclient. I just test it and it wroks great.
> I tested one of your codes, ClientApp.java, to see how it works, so it was working perfectly. Thank you for the clean examples, [only client.setTimeout(30000); /* milliseconds */  was giving error]
> 
> Well my problem is  httpclient does not work with this url http://www.shoemall.com
> Actually my java program could not read above url, and that was the main reason I tried to use httpClient. 
> But still I faced the same problem with httpClient.
> 
> Can you please give it a try, just try to read that page, and see what happens.
> 
> I greatly appreciate your help, or any guide for solving my problem.
> 
> 
> With Regards,
> Navid