I am developing an Phonegap app(Android), which uses javascript/HTML5 localStorage. The app works fine, however when I add the Admob to the app, the localStorage not work. Meaning the stored values are delete when the app is force closed or the phone is restarted.
public class TestActivity extends DroidGap {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
super.loadUrl("file:///android_asset/www/index.html");
// ADMOB: If comment, work.
/*
LinearLayout layout = super.root;
AdView adView = new AdView(this, AdSize.BANNER, **MY_CODE_ADMOB**);
layout.addView(adView);
AdRequest request = new AdRequest();
adView.loadAd(request);
*/
}
}
Thanks!!
See Question&Answers more detail:os