Article View: alt.pl.comp.lang.csharp
Article #9720HttpWebRequest a Chunked;
From: adasiek
Date: Fri, 28 Oct 2005 20:26
Date: Fri, 28 Oct 2005 20:26
21 lines
1542 bytes
1542 bytes
Witam!
otoz mam stronke WWW, ktora chce pobrac za pomoca klas:
HttpWebRequest, HttpWebResponse:
HttpWebRequest zapytanie =
new (HttpWebRequest)WebRequest.Create("host/sciezka/");
HttpWebResponse odpowiedz = (HttpWebResponse)zapytanie.GetResponse();
Stream strumien = odpowiedz.GetResponseStream();
strumien.ReadToEnd() // error !!!
problem pojawia sie, jezeli serwer WWW odpowiada mi naglowkiem
Transfer-encoding: chunked; niestety serwer musi tak odpowiadac,
bo moje zapytanie musi byc HTTP/1.1 (ze wzgledu na vhosty);
StreamReader nie chce tego ruszyc; a klasa HttpWebResponse AFAIK
nie ma zadnej innej metody, ktora zwracalaby tresc odpowiedzi :(
czy wiecie jak sie dobrac do takiej pofragmentowanej odpowiedzi??
pzdrv;
adas;
Technical Details
Message-ID:
<Xns96FDE3EBC47A9adasiek.podolany.net@127.0.0.1>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.nask.pl!news.nask.org.pl!newsfeed.tpinternet.pl!atlantis.news.tpi.pl!news.tpi.pl!not-for-mailShow Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!newsfeed.gazeta.pl!news.nask.pl!news.nask.org.pl!newsfeed.tpinternet.pl!atlantis.news.tpi.pl!news.tpi.pl!not-for-mail From: adasiek <podolany@poczta.wp.pl> Newsgroups: alt.pl.comp.lang.csharp Subject: HttpWebRequest a Chunked; Date: Fri, 28 Oct 2005 20:26:14 +0000 (UTC) Organization: Telekomunikacja - nigdy! Lines: 21 Message-ID: <Xns96FDE3EBC47A9adasiek.podolany.net@127.0.0.1> NNTP-Posting-Host: pk154.poznan.sdi.tpnet.pl X-Trace: atlantis.news.tpi.pl 1130531174 2307 217.96.164.154 (28 Oct 2005 20:26:14 GMT) X-Complaints-To: usenet@tpi.pl NNTP-Posting-Date: Fri, 28 Oct 2005 20:26:14 +0000 (UTC) User-Agent: Xnews/5.04.25 Hamster/2.0.0.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit