An iOS Phonegap application using XMLHTTPRequest to send to a secure web service returns a return status of 0

I am developing an iOS application using phone clearance and stuck at a point. When I try to access a web service using XMLHTTPRequest (), I get the status 0. When I look at this request in a script, I see that there is a correct answer.

I have already looked at links in which the PhoneGap application is not limited to policies of the same origin. But I still can not solve this problem.

The only difference that I could see was that the URL I am accessing is secure https. Is there something like https requests, crossdomain is not allowed.

Please, help. I've been stuck here all day today.

+4
source share
1 answer

Could it be that the https web service certificate you point to is self-signed?

If so, there is no way to use anything other than a secure, well-known certificate using ajax PhoneGap calls.

See: https request does not work in phonegap-iphone application

Another option might be related to your version of Xcode: run an https request in a phone gap

0
source

All Articles