Quantcast
Channel: Gik's notes » http
Browsing all 3 articles
Browse latest View live

Image may be NSFW.
Clik here to view.

Get file size via HTTP

How to get file size with http-request ? HttpWebRequest req = (HttpWebRequest)WebRequest.Create("http://example.com/"); req.Method = "HEAD"; HttpWebResponse resp = (HttpWebResponse)(req.GetResponse());...

View Article



Read http response correctly!

If you’re using apache http client, method getResponseBodyAsString() set the following: 01 02 2012 17:44:52,484 WARN main org.apache.commons.httpclient.HttpMethodBase - Going to buffer response body of...

View Article

Image may be NSFW.
Clik here to view.

Response.Redirect and Thread was being aborted in C#.NET

To prevent error “Thread was being aborted” while Response.Redirect() method execute, use second parameter equals to FALSE: Response.Redirect("http://google.com", false); Also proof,...

View Article
Browsing all 3 articles
Browse latest View live




Latest Images