My Application is a Mobile Hybrid app I mean Phonegap app. I am trying to persistent cookie to avoid login every time, say for example 7 days.
To achieve this I am making an AJAX call to the server then server will set the cookie for 7 days, but I am loosing the cookie when I restart the Phone this is happening both in Android and IOS in Android I am using the below solution.
Is there any similar solution in IOS. I am not sure how to achieve this in IOS. Appreciate your help.
To achieve this I am making an AJAX call to the server then server will set the cookie for 7 days, but I am loosing the cookie when I restart the Phone this is happening both in Android and IOS in Android I am using the below solution.
Code:
onCreate()
CookieSyncManager.createInstance(this);
onResume()
CookieSyncManager.getInstance().startSync();
onPause()
CookieSyncManager.getInstance().stopSync();
Is there any similar solution in IOS. I am not sure how to achieve this in IOS. Appreciate your help.
Last edited by a moderator: