NimbleKit - fast iOS app development

Advert Integration

Ask questions and share your skills here

Advert Integration

Postby HalfMoon » Sat Aug 22, 2009 1:42 pm

I've got an app that I was considering releasing as as free/advert supported.

Before I get started and try and figure out how to integrate Admob, Mobclix, Pinch Analytics etc - Has anyone else successfully added ads to a NimbleKit app yet?
:D
User avatar
HalfMoon
NimbleKit Guru
 
Posts: 662
Joined: Thu Jun 04, 2009 6:21 pm
Location: Brighton, UK

Re: Advert Integration

Postby brass » Sun Aug 23, 2009 3:06 am

check out the sample uploaded by hugh over at viewtopic.php?f=5&t=329&p=1310&hilit=redirect#p1310

I am going to implement something like this for one of my planned free apps, seems like it could be for using 1 or 2 ads.
brass
 
Posts: 64
Joined: Mon Aug 03, 2009 9:00 pm

Re: Advert Integration

Postby HalfMoon » Sun Aug 23, 2009 3:25 pm

Hey brass,

Thanks for that - it looks like a easy way to add ads. Just drop in the ad networks html/js to the first page along with a "NKIsInternetAvailable" to skip the page if no internet connection available.

I was thinking more along the lines of integrating the AdMob/AdWhirl sdk's natively with the app by using an Obj C mix - this way you would get all the benefits of the ad network like app tracking, analytics etc as well as the ad serving.
User avatar
HalfMoon
NimbleKit Guru
 
Posts: 662
Joined: Thu Jun 04, 2009 6:21 pm
Location: Brighton, UK

Re: Advert Integration

Postby brass » Sun Aug 23, 2009 6:32 pm

yeah i could see the benefits of that as well. Unfortunately i am not sure how to do that. I am simply trying to or going to try to sell my apps to 1 individual company and charge for my other apps. Would like to know how to do it though, could always use more tools in the tool box.
brass
 
Posts: 64
Joined: Mon Aug 03, 2009 9:00 pm

Re: Advert Integration

Postby HalfMoon » Mon Aug 24, 2009 6:32 pm

Looking at AdMob's wiki, they don't recommend showing javascript AdMob ads as part of a UIWebView but I tried it and it works (for now anyway) so that could be a possibility. I'm still keen to integrate them "properly" though - I've put their ads into other (non-nimble) apps via the SDK with Interface builder (which was a doddle) but as we can't use IB with NimbleKit they need to be added programatically.

The readme suggests:
Code: Select all
Create an AdMob delegate class; it can be as simple as a class that only implements -publisherId:.
Add the following code to your view creation (modify as appropriate):

   AdMobView *ad = [AdMobView requestAdWithDelegate:<your delegate>]; // start a new ad request
   ad.frame = CGRectMake(0, 432, 320, 48); // set the frame, in this case at the bottom of the screen
   [self.window addSubview:ad]; // attach the ad to the view hierarchy; self.window is responsible for retaining the ad

but this is where I get lost in Obj-C (hence using NK! ;) ). I'm looking into how LiquidGear calls ads but I'm not sure if I can garner anything from their method as the NK library is obfuscated.

I'll keep poking around and if anyone with better Obj-C knowledge than I has any ideas, please add your input.
8-)
User avatar
HalfMoon
NimbleKit Guru
 
Posts: 662
Joined: Thu Jun 04, 2009 6:21 pm
Location: Brighton, UK

Re: Advert Integration

Postby billymay » Tue Aug 25, 2009 3:15 am

I found Admob kinda hard to get installed into my project... kept failing. Let me know if someone knows how to integrate either Admob or Adwhirl. Thanks!

Billy
billymay
 
Posts: 73
Joined: Mon Aug 24, 2009 9:23 pm


Return to How To...

Who is online

Users browsing this forum: No registered users and 0 guests