0

I am building a web service based on PHP language. Browser shows the exact data. But while i am trying get data from my iPhone app then shows the following error

  • kCFURLErrorBadURL = -1000

How to solve the problem from Server End (PHP) ?

Md Mahbubur Rahman
  • 2,065
  • 1
  • 24
  • 36
  • might help http://stackoverflow.com/questions/12383602/cfnetwork-error-the-connection-failed-due-to-a-malformed-url – janusfidel Sep 12 '12 at 12:20
  • @janusfidel, it solves at device end. but i need server end. – Md Mahbubur Rahman Sep 12 '12 at 12:22
  • 1
    Also check the URL itself, the browser might perform small corrections which are not done with your connectivity class. – A-Live Sep 12 '12 at 12:22
  • 1
    If you are using the same URL it's easy to check it manually (with your eyes i guess or you can try to search for the online validator), it must conform RFC 1738 standard. If the URL is composed, check it's construction. For example `https://www.google.com/?q=search text` is transformed into `https://www.google.com/?q=search%20text` by browser. – A-Live Sep 12 '12 at 12:28

1 Answers1

1

The browser might bring correction for the URL while the connectivity classes either don't do them or do not the same corrections.

The URL must conform RFC 1738, check the URL you are using and make required corrections (preferably on the server side).

A-Live
  • 8,904
  • 2
  • 39
  • 74