MoPub banner auto load issue fix


mopub-twitter-fabric-tool-set-suite-logo I use MoPub mediation to show banner ads in my mobile apps. There is one issue I faced and today I am going here to share the solution. In my game app, I show banner ad at the end of game over page. And when user go to other screen i hide the banner ad. But the problem I noticed that the banner ad is auto loading though it is not showing when user is in another screen.

My first solution was removing the banner ad view from master view and set the banner ad view to nil, but it not solved. Later I found the following solution fix the issue.

 

[self.adView removeFromSuperview];
[self.adView stopAutomaticallyRefreshingContents];
self.adView = nil;

So the difference between MoPub and AdMob banner handling is, in AdMob if you remove the banner from master view it no longer request for additional ads, whereas in MoPub you’ve to manually call to stop auto load.

mahmud ahsan

Love computer programming and write occasional blog post. In my early career I worked mostly on web based application and since 2011, I exclusively working on iPhone and android applications. I work at home, father of a nice kid and husband of a beautiful wife. [My Business | Twitter | Linkedin]

You may also like

Comments are closed here.

About Me

Hi I am Mahmud Ahsan. I Love computer programming and write occasional blog post. In my early career I worked mostly on web based application and since 2011, I exclusively working on iPhone and android applications. I work at home, father of a nice kid and husband of a beautiful wife. [My Business | Twitter | Linkedin]

Twitter Feed

Fanpage