为flash.net.URLLoader对象访问HTTP响应头? [英] Access HTTP response headers in for flash.net.URLLoader object?
问题描述
有没有一种方法来使用Flash时,从HTTP结果访问的响应头/ Flex的的URLLoader
?
Is there a way to access the response headers from an HTTP result when using Flash/Flex's URLLoader
?
设置的请求的标题是可能的,因为正在访问的响应code 的,但得到的保持实际响应头似乎明显缺乏..
Setting the request headers is possible, as is accessing the response code, but getting a hold of the actual response headers seems to be conspicuously lacking...
具体而言,我想获得一个保留的的Last-Modified
响应头。
Specifically, I would like to get a hold of the Last-Modified
response header.
推荐答案
抱歉。在这里回答我的问题,但AIR介绍了<一href="http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/net/URLLoader.html#event:htt$p$psponseStatus"><$c$c>URLLoader.htt$p$psponseStatus$c$c>事件其中包括 responseHeaders响应
属性(外加 responseURL
属性加分)。
Oops. Answering my own question here, but AIR introduces the URLLoader.httpResponseStatus
event which includes a responseHeaders
property (plus a responseURL
property for brownie points).
值得庆幸的是,我的问题是为AIR应用程序,这样可以解决我的问题。它仍然是一个有点令人震惊的是无风闪光/ Flex应用程序似乎不能访问的响应头。
Thankfully my question was for an AIR application, so that solves my problem. It's still a bit shocking that non-AIR flash/flex applications cannot seem to access the response headers.
这篇关于为flash.net.URLLoader对象访问HTTP响应头?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!