Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 4    Views: 101

Silvia SuperStar
Android Fan
Profile
Posts: 54
Reg: Feb 06, 2014
Ibiza
540
02/19/14 09:07 PM (11 years ago)

How to display standard web banners instead admob inside the app?

Hi all, I know how to add admob ads thanks to the sandeep "how to" documment. But i want to display a web banner promoting one of my apps instead admob banners. Any idea? Thanks
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/19/14 09:39 PM (11 years ago)
I don't think you can do this with admob, although I haven't used it enough to really know. If you're wanting to alway display the banner for your app, you could create some custom code to show an image view equal to the size of your banner and display it that way. Or, you could use this approach and combine it with a random number generator so that the app randomly decides whether to use the ad code or the custom banner code. Takes a little bit of skill, but not too bad if you know what you're doing.
 
Silvia SuperStar
Android Fan
Profile
Posts: 54
Reg: Feb 06, 2014
Ibiza
540
like
02/19/14 10:09 PM (11 years ago)
What size is recommended for banners? I suppose i need to make a few.
 
chris1
Code is Art
Profile
Posts: 3862
Reg: Aug 10, 2012
Austin, TX
50,120
like
02/19/14 10:18 PM (11 years ago)
Hmm - not sure. If you're making a custom banner to advertise your own stuff, you can make it whatever size you want. If you're trying to match what an ad service like admin uses, you can always try to take a screenshot of one of their ads and use a photo editor like Photoshop to figure out the dimensions.
 
SmugWimp
Smugger than thou...
Profile
Posts: 6316
Reg: Nov 07, 2012
Tamuning, GU
81,410
like
02/20/14 12:54 AM (11 years ago)
I do my own banners… of course, my market is pretty small, so I don't need a sophisticated system. I typically either use my own plugin, or modify chris1 or Susan's menu plugins to half height images, and then use those as my 'banner' across the top of my screen. It eats about 20 percent of the screen, and is a 'constant'. They end up being in the neighborhood of around 150 x 600 'displayed' but I usually make them 2x larger for Android devices, and let everything autoscale a bit… But like Chris says… it's really up to you. Are you planning to build for one device, or do they all have to work? Big banners on a dinky android screen is pretty miserable to deal with. Most android phones are big, but not all of them. The banners I rotate using a rotator script based on a webserver, that feeds banners that I place in a directory. I can't remember where I got it from; I didn't write it. But I keep a copy here: https://dl.dropboxusercontent.com/u/115208762/rotateimage.txt just change the suffix from txt to php and plop it on your server in a directory with images scaled for your particular purpose. Cheers! -- Smug
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.