Home>

I would like to display admob ads using admob-free on monaca.

◆ Development environment
monaca
◆ OS
iOS
◆ Plug-in
cordova-plugin-admob-free

I introduced it with reference to various sites, and it is displayed properly with the test ID, but when I use the actual ID, the banner frame remains blank.

The following js file is read as an external file in the header.
* The admob ID is rewritten and posted for testing.

On the management screen of admob, it seems that the advertisement request itself is made.

As a point to be worried about, there is a part to link with the App store on the management screen of admob,
I haven't made a link yet because the app doesn't appear even if I search.
* More than 10 days have passed since the release

Is this the cause?

var admobid = {}
if (/ (android) /i.test(navigator.userAgent)) {// for android&amazon-fireos
  admobid = {
    banner:'ca-app-pub-3940256099942544/6300978111',
    interstitial:'ca-app-pub-3940256099942544/1033173712',
  };
} else if (/ (ipod | iphone | ipad) /i.test(navigator.userAgent)) {// for ios
  admobid = {
    banner:'ca-app-pub-3940256099942544/6300978111',
    interstitial:'ca-app-pub-3940256099942544/1033173712',
  };
}
document.addEventListener ('deviceready', function () {
  admob.banner.config ({{
    id: admobid.banner,
    isTesting: false,
    autoShow: true,
  });
  admob.banner.prepare ();
  admob.interstitial.config ({{
    id: admobid.interstitial,
    isTesting: false,
    autoShow: false,
  });
  admob.interstitial.prepare ();

}, false);
document.addEventListener ('admob.banner.events.LOAD_FAIL', function (event) {
})
document.addEventListener ('admob.interstitial.events.LOAD_FAIL', function (event) {
})
document.addEventListener ('admob.interstitial.events.LOAD', function (event) {
})
document.addEventListener ('admob.interstitial.events.CLOSE', function (event) {
  admob.interstitial.prepare ();
})