English 中文(简体)
xmlHttpRequest and returned url
原标题:

With help of xmlHttpRequest I make a server query. After that the server is redirecting to another page (e.g. "http://site.com/index.html;var=123")

The question is - how can I get full url(side.com/index.html;var...)?

The code is executed with Adobe Air.

thanks

问题回答

I presume you mean, you are making an xmlHttpRequest inside the HTML control of Adobe Air. AIR provides no functionality on trapping calls originating from the web page that are not a part of the user action. Thus, your AJAX query will move the same way as in a browser. The only luck you may have is with JavaScript to trap the response of the call and use it.

On a side note, you may try loading the same URL with URLLoader/URLStream using a HEAD request in Adobe AIR, with URLRequest.followRedirects set to false. Then listen to HTTPStatusEvent and read the Location response header. HTH.





相关问题
Can an AIR application access its own digital signature?

All AIR installation files must be digitally signed (http://help.adobe.com/...). Is there a way for an AIR application to access this signature information at runtime? Say, I m distributing client-...

What are the best development tools to use in this project?

I am currently devising 3 database desktop applications for different users in a manufacturing company (one for the accounting department, sales department, production department). All applications ...

Authenticating and tracking users in a JSON webservice

I have contact management / CRM application used in-house by our company, It is a web based app and thus uses a lot of Ajax. Most of the data is JSON, and the backend server uses PHP with MySQL as the ...

Adobe AIR: detect en_GB locale

Is there a way to detect if the user is running the AIR application under en_GB locale on Windows? Capabilities.language returns only "en" and Capabilities.languages[0] returns "en_US" :(

AIR评估业绩缓慢的原因?

我试图用Windows XP(SP3)Adobe AIR的表现来缓解一个奇怪的问题。 我们从遥远的服务器到当地QLQ数据库的同yn数据,以及某些机器的数据,这一过程需要......。

xmlHttpRequest and returned url

With help of xmlHttpRequest I make a server query. After that the server is redirecting to another page (e.g. "http://site.com/index.html;var=123") The question is - how can I get full url(side.com/...

热门标签