Please help me with ads in webview


#1

This is my script in demo.js

var banner = Cocoon.Ad.AdMob.createBanner(“ca-app-pub-6970804331234424/3752943760”);
var interstitial = Cocoon.Ad.AdMob.createInterstitial(“ca-app-pub-6970804331234424/8598076334”);

var banner = Cocoon.Ad.AdMob.createBanner();

banner.on(“load”, function(){
console.log("Banner loaded " + banner.width, banner.height);
});

banner.on(“fail”, function(){
console.log(“Banner failed to load”);
});

banner.on(“show”, function(){
console.log(“Banner shown a modal content”);
});

banner.on(“dismiss”, function(){
console.log(“Banner dismissed the modal content”);
});

banner.on(“click”, function(){
console.log(“Banner clicked”);
});

banner.show();

var interstitial = Cocoon.Ad.AdMob.createInterstitial();

interstitial.on(“load”, function(){
console.log(“Interstitial loaded”);
});

interstitial.on(“fail”, function(){
console.log(“Interstitial failed”);
});

interstitial.on(“show”, function(){
console.log(“Interstitial shown”);
});

interstitial.on(“dismiss”, function(){
console.log(“Interstitial dismissed”);
});

interstitial.show()

I put in index.html this

<script type="text/javascript" src="cordova.js"></script>
	<script type="text/javascript" src="js/demo.js"></script>
    <script>
        function main() {
                // You application code
            };
            document.addEventListener('deviceready', main, false);
    </script>

but the ads doesnt show
Somebody can help me please?


#2

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.