Turn off app in IOS through PhoneGap API - iphone

I have a html5 app for iphone using phonegap. I check for internet connection for the necessary first update, how do I turn of the app if the user does not have an internet connection? Thanks in advance. As I said I have full access to phonegap api!

if you want to deploy your app to the app store, you can not update the app under the covers. You have to submita new version to apple and let the users update your app.
If you just want to know wether your device is online you can use the Phonegap online offline events. See: http://docs.phonegap.com/en/1.4.1/phonegap_events_events.md.html#online and http://docs.phonegap.com/en/1.4.1/phonegap_events_events.md.html#offline

Related

iPhone: Access Camera and Album from Web app

I want to develop a web app using html5, js. One of the feature is to launch device Camera and record video, take a picture and access photo album. Is it possible to access via web app if i develop? I saw in the forums that, it is saying not possible in some places and it is possible in some places. I would like to know, is it really possible to access directly camera and album etc. ?
Please suggest!
Thank you!
It's not possible to access phone camera using Web app, as the "Web APP" typically runs in the browser of device.
Though there are some frameworks (like Phonegap) allows you to embedd your web app into native container. With this approach and added libraries from such framework you can access some of those native API's and Device Hardware.
One Possible solution is,
Create one app and distribute it using app store
using your webapp, you can connect to above app using url-scheme
http://code.google.com/p/iphone-photo-picker/
go to above link, where you can find complete code for it.

Phonegap: Can iPhone web app access/check for wifi connections

I have tried looking for some answers but could not get anything concrete from the other questions in here.
I am looking for an answer to these two questions:
Using PhoneGap, if I create an iPhone web app, can I use it as
plain web app (i.e. without using iTunes to deploy it)? Just via a
web url?
Using PhoneGap, can an iPhone web app check for wifi
connectivity? i.e. If wifi/3g is available, if wifi is available,
can it scan for ssids.
Thanks for any help in advance.
You can create host the web app on your own server (or local). Then it is accessible via web url. If you want to use it as a normal app (there are differences - phonegap uses few native plugins for better experience), then you must have a developer license from apple and then deploy it to your device. Otherwise you can only use the simulator. You can also use Safari + USB to debug your app using the browser.
It is possible but limited. Only certain functionalities are available. Check out the following plugin for cordova (phonegap):
cordova-plugin-wifi
Good luck!

MDM API Integration in iPhone

I am trying to do an enterprise application which need to list all the installed apps in iPhone and also should allow the user to delete some apps from current application.I know this is not possible using any direct API's.But I found that using MDM API's it is possible. I had gone through the documents about this in apple's website http://images.apple.com/iphone/business/docs/iPhone_OTA_Enrollment_Configuration.pdf
But I am not sure where I need to start. What are the steps I need to follow to access these APIs in the iPhone side. Do I need to perform all these steps programatically when I open the app or else these will be handled by server.
Please share your ideas about how to implement this from a developer point of view.
Thanks in advance.
Apps are not able to do any MDM, it can only be done by the server, that is managing the device.
Apple has a session video from WWDC 2010 that shows how this is done.

Can a hosted application leverage the PhoneGap API?

I am building a hosted mobile application so I can write once and deploy to many mobile platforms. My plan is to write a native application with a single screen that is a browser that navigates to my hosted application. Of course this is so our application is in the App Store, Android Market, etc.
Is it possible to use the PhoneGap JavaScript so my hosted applications can use local APIs? For example, I would like to be able to upload pictures taken from the camera.
Short answer: no.
More information: PhoneGap: It's possible to use only the phonegap.js and it's functions only in a Website (doesn't want an App only a Webpage)?
Short answer
No. You need to add pctures upload logic in each framework
In addition to what has been answer it will also depend on your application store offering. If you're intending to offer the app in the iPhone App Store, these kind of apps aren't permitted. In the guidelines it states that apps that basically launch a browser or UIWebView will be rejected.
Additionally, you could always create the app as a "home screen" app, that runs without the chrome, etc on the iPhone. Hope this helps.

updating iPhone apps via the web

I'm working on an eBook app for the iPhone. Given the time it takes for Apple to review and publish updates, I'm considering adding a feature to update the content via my own (Google App Engine-powered) web site.
This would allow me to update the content at will, rather than being at the mercy of the App Store review team. Is Apple likely to reject this kind of behavior in an app? I've asked in the Apple Developer forums, but received no response.
We have developed an application on the App Store that will go our web server and get new content when new content is available and store it on the iPhone. You should not have any problem as long as the content is not offensive. This could lead to your application being removed from the app Store. I've also heard that they may make your app 17+ because of getting content from the web.
You probably received no response because no one knows for sure. Apple has allowed apps that embed webkit before, but it has also rejected them as well.
iphone + web hybrid apps perfectly ok i think, not sure why apple would be concerned.