Async NW event.response -- can I get to the HTTP response header fields?

Hi~

First forum post; new to Corona. Searched, but didn’t find an answer to this one.

I’m writing an app that connects to a web-services layer via HTTPS. Have the POST request working fine. However, for reasons I won’t get into, I’m having to fish out and use a session cookie for user validation (don’t ask) from the response. If I go straight Lua socket it looks pretty easy, but then it’s blocking not async, and async is required.

Can anyone point me at where/how I can get the http header fields from the response? Event.response doesn’t seem to include them (or I’m not seeing them).

Any help greatly appreciated.

Thanks!

P.S. I’m more of a C++/Objective-C guy, with now just over 30 days in Lua/Corona, so if this is obvious and I missed it, blame the newbie.
[import]uid: 5670 topic_id: 17699 reply_id: 317699[/import]

It seems that Corona is lacking this feature for now. I applied it as a bug and future feature.

http://developer.anscamobile.com/forum/2011/11/25/http-headers-support-response-get-method-networkrequest [import]uid: 106083 topic_id: 17699 reply_id: 69861[/import]

I resume this thread to know if it is now possible to get the http header from a response. [import]uid: 104317 topic_id: 17699 reply_id: 106389[/import]

This isn’t the answer you’re looking for, but you can turn that LuaSocket blocking function into an asynchronous call with Coroutines. Take a look at this example: http://stackoverflow.com/questions/5795419/lua-socket-asynchronous-calls [import]uid: 61899 topic_id: 17699 reply_id: 106400[/import]