Goldengate icon indicating copy to clipboard operation
Goldengate copied to clipboard

Is it possible to work around the local URLs limitation?

Open radex opened this issue 11 years ago • 1 comments

I'm a little worried that albeit local URL loading was added, it won't ship until iOS 9. Even if they do ship it in iOS 8.2, OS X will surely have to wait until 10.11. That's kinda too long to wait.

Is it possible to (somehow!) work around this? Somehow fake a local server, perhaps? I doubt it's possible, but even if you can do it on one of the platforms, that's better than nothing.

radex avatar Nov 18 '14 23:11 radex

No indication of local URL loading shipping before iOS 9/OSX Weed.

But it is possible to work around it using a local web server (seriously, even on iOS). You have to deal with a lot of crap though:

  • file:// doesn't work, so you have to translate that to a local server endpoint
  • you have to secure yourself from other apps trying to connect to the server (cookie with auth token, for example)
  • WebSQL doesn't work, so you need to use a bridge to SQLite

Cordova has a quite complete implementation of this: https://github.com/apache/cordova-plugins/blob/master/local-webserver/src/ios/CDVLocalWebServer.m

radex avatar Apr 04 '15 21:04 radex