Swift 4.2, iOS 12.x
Essayer de mettre en œuvre AdMob dans mon application, mais pas très loin d'obtenir.
- Création d'un compte AdMob, semble correct?
- clés Ajouté NSAppTransportSecurity à info.plist ok?
Ajout ce code pour charger une bannière ajouter ok.
bannerView = GADBannerView(adSize: GADAdSize(size: CGSize(width: 320, height: 50), flags: 0), origin: CGPoint(x: 0, y: 0)) bannerView.adUnitID = ca-app-pub-A/B // changed this code in this post bannerView.rootViewController = self.view?.window?.rootViewController bannerView.delegate = self let request = GADRequest() request.testDevices = [ kGADSimulatorID ] bannerView.load(request) self.view?.window?.rootViewController?.view.addSubview(bannerView)
classe étendue pour soutenir GADBannerViewDelegate; obtenir un rappel sur ce qui dit l'erreur, aucune annonce à afficher. La console en fait le signale.
18/12/2018 11: 49: 35,468445 + 0100 DeX [1547: 900808] WF: _WebFilterIsActive retour: OUI 18/12/2018 11: 49: 35,468729 + 0100 DeX [1547: 900808] WF: _userSettingsForUser mobile: {filterBlacklist = (); filterWhitelist = (); noOverridingAllowed = 1; restrictWeb = 1; useContentFilter = 1; useContentFilterOverrides = 0; whitelistEnabled = 0; } 18/12/2018 11: 49: 35,468821 + 0100 DeX [1547: 900808] WF: Vérification https://googleads.g.doubleclick.net/mads/static/sdk/native/sdk-core-v40.html est en contentFilterOverriddenBlackList 18/12/2018 11: 49: 0100 + 35,469159 DeX [1547: 900808] WF: Vérification https://googleads.g.doubleclick.net/mads/static/sdk/native/sdk-core-v40 .html est en contentFilterOverriddenWhiteList 18/12/2018 11: 49: 35,513610 + 0100 DeX [1547: 900808] WF: * WFLSMMap initWithMap: impossible de récupérer le seuil à partir du fichier carte. 18/12/2018 11: 49: 0100 + 35,518259 DeX [1547: 900808] WF: catégorie WFLSMScoreNormalizedMap: 1 min: max 0,338760: 0,663066 portée: 0,324306 18/12/2018 11: 49: 0100 + 35,518377 DeX [1547: 900808 ] WF: catégorie WFLSMScoreNormalizedMap: 2 min: max 0,336934: 0.661240 portée: 0,324306 18/12/2018 11: 49: 0100 + 35,518439 DeX [1547: 900808] + [WF: WFJudge defaultJudge] map: / System / Library / PrivateFrameworks / WebContentAnalysis.framework / content_filter_map3 18/12/2018 11: 49: 35,518559 + 0100 DeX [1547: 900808] WF: page non la peine d' analyser [longueur de pageContent]: 7 [count [images auto]] == 0 [[self scriptBlocks] compter]: 2 18/12/2018 11: 49: 0100 + 35,518693 DeX [1547: 900808] WF: WebFilterEvaluator: addData: https://googleads.g.doubleclick.net/mads/static/sdk/native/sdk- core-v40.html ne soit pas bloqué: 'googleads.g.doubleclick.net' est pas explicite 18/12/2018 11: 49: 0100 + 35,518760 DeX [1547: 900808] WF: WebFilterEvaluator: addData: « googleads.g. doubleclick.net » à https://googleads.g.doubleclick.net/mads/static/sdk/native/sdk-core-v40.html n'est pas bloc * ked erreur *** Demande Erreur: Aucune annonce à afficher.
Qu'ai-je manqué ici? Créé le compte hier après-midi, donc moins de 24 heures passées depuis que je l'ai fait?