how to get the http header in asynchronous request mode using ASIHHTTP
<p>I hope to display the download file size by reading http header.</p>

<p>I know there is way do this:</p>

<pre><code>ASIHTTPRequest request = [ASIHTTPRequest requestWithURL:url];
[request startSynchronous]; NSString poweredBy = [[request responseHeaders] objectForKey:@"X-Powered-By"];
NSString *contentType = [[request responseHeaders] objectForKey:@"Content-Type"];
</code></pre>

<p>but this is Synchronous mode, in Asynchronous mode it can be done as below: </p>

<pre><code>(void)requestFinished:(ASIHTTPRequest *)request { unsigned long long contentLength = [request contentLength]; }
</code></pre>

<p>but 'requestFinished' is at the end of download.
Is there an event to get the http header info at the beginning of download?</p>

<p>Thank</p>

<p>interdev</p>
