App is for Android and iOS
Hello my need is to let my App perform ajax requests (in example 1 request/minute to check something) even if the user close it (or the OS close it).
I tried plugins to let app run in background but:
1) this is not what I need, because the app could be closed by recent apps
2) I've read that this caveat is not accepted by stores
The best should be let my app open some "process" that would be indipendent from the status of my app (in foreground, closed or something like that). Another solution would be just to let my app receive pushes even if closed.
Is there any solution? thank you
Alessandro -- what you are trying to do would be best accomplished via a custom plugin -- or as a separate standalone service. In either case, you'd need to write the code in the native language for the platform (meaning Java for Android and Objective C for iOS). This is outside the scope of the XDK and standard Cordova apps. To find out more about Cordova plugins, see these docs > https://cordova.apache.org/docs/en/latest/guide/hybrid/plugins/