[ https://issues.apache.org/jira/browse/CB-1406?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13453329#comment-13453329
]
Jochen Magnus edited comment on CB-1406 at 9/12/12 6:36 AM:
------------------------------------------------------------
Michal,
probably you got the status 0 result due to XHR's same origin policy. The source file and
the test.txt file, which my examples try to load, must have the same server origin in the
case of a webapp.
I had tested exactely that the status 0 problem I described, is *not* a result of the same
origin policy. The webapp example is working either with iOS 5 or iOS 6. The native version,
using Cordova 2.1rc2, is working only with iOS 5 (in this case the same origin policy does
not matter!)
You can call my working example from http://live.rhein-zeitung.de/workertest.html
was (Author: ioma):
Michal,
probably you got the status 0 result due to XHR's same origin policy. The source file and
the test.txt file, which my examples try to load, must have the same server origin.
I had tested exactely that the status 0 problem I described, is *not* a result of the same
origin policy. The webapp example is working either with iOS 5 or iOS 6. The native version,
using Cordova 2.1rc2, is working only with iOS 5.
You can call my working example from http://live.rhein-zeitung.de/workertest.html
> HTTP-Get via XHR in Web Workers always return status 0 under iOS 6 (Beta 4)
> ---------------------------------------------------------------------------
>
> Key: CB-1406
> URL: https://issues.apache.org/jira/browse/CB-1406
> Project: Apache Cordova
> Issue Type: Bug
> Components: iOS
> Affects Versions: 2.1.0
> Environment: all iOS devices and simulators
> Reporter: Jochen Magnus
> Assignee: Shazron Abdullah
> Labels: HTTP, WebWorker, XHR
> Fix For: 2.2.0
>
> Attachments: testworker.js, workertest.html
>
>
> HTTPRequests in the Web Workers ending always with http.readyState==4 (that's the ready
state) but with http.status==0, which is an undefined status (normal is 200 for "o.k."). The
file is requested from and fully deliverd by the webserver.
> This happens under iOS 6 Beta 4 but not under iOS 5.x where the same app with the same
Cordova version works well.
> The problem did not occur with XHR in the native programs main thread nor in non-native
HTML5-apps (WebApps without the use of Cordova).
> A Xcode test project is available.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
|