Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70612

Having trouble setting up Facebook ads in my ionic project

$
0
0

@marcos702 wrote:

so far I have

angular.module('mobionicApp', ['ionic','ngCordova']}
.run(function($ionicPlatform, $cordovaFacebookAds,) {
$ionicPlatform.ready(function() {
var ad_units = {
ios : {banner:"your_ad_place_id",},
android : {banner:"your_ad_place_id",}
};
var adid = (/(android)/i.test(navigator.userAgent)) ? ad_units.android : ad_units.ios;
if(FacebookAds) FacebookAds.setOptions({
isTesting: true,
deviceHash: ''
});
if(FacebookAds) FacebookAds.createBanner( {
adId: adid.banner,
position:FacebookAds.AD_POSITION.BOTTOM_CENTER,
autoShow:true
});
})

but I receive errors at the end what do I do? I saw someone explain this http://stackoverflow.com/questions/26562967/fb-audience-network-in-cordova-apps#

how do I use $cordovaFacebookAds.showBanner();

If any one can help me out, it would be great.

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70612

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>