Can I run an HTTP server on a mobile platform?
Asked Answered
M

1

16

I am building a webapp that cannot be put into the app store (security reasons). The webapp needs access to more data than can be held in localStorage or other offline-storage means (let's say up to 1GB of data).

My idea of a solution is to code up an HTTP server for Android and iOS, and then get/post data with AJAX so I can have access to the device's internal storage.

My question is,

Can this be done on iOS and Android?

By 'Can', I mean both technically (is there API access to the required components, and can it be always running in the background) and legally (is it consistent with the terms of service of both the App Store and Android Marketplace).

I don't know much about either platform and the capabilities, but I could figure it out if I was confident that it is possible.

The reason for this is so that large amounts of data can be made available all the time to a webapp, regardless of the presence of wifi or a cell-tower.

Megillah answered 10/9, 2011 at 23:52 Comment(0)
M
17

Yes

For a full app that uses an http server, check out Websharing on Android.

Mortensen answered 10/9, 2011 at 23:59 Comment(4)
Cool! That works on non-jailbroken units, right? What about iOS?Megillah
@tjameson yes, it's a normal app, doesn't require rooting. It's a very cool idea!Mortensen
That's really sexy. I'd really like to know if it's possible on iOS too.Megillah
Thanks for the links! This question probably ought to be marked as duplicate, but whatever, thanks for the help.Megillah

© 2022 - 2024 — McMap. All rights reserved.