2
當我的應用加載時,它會爲整個會話顯示相同的橫幅廣告。是否有一種方法可以在新廣告中循環使用,例如刷新當前的橫幅以顯示下一個廣告?這正在破壞我的印象和轉換。正如一則廣告所示,整個會話對用戶來說並不太吸引。我知道,通過閱讀loadAd()與它有關的文檔,但我似乎無法弄清楚如何實際實現該時間間隔。這裏是我現在正在使用leadbolt進行的代碼,代碼中顯示了橫幅廣告。這是 - (void)viewDidLoad的一部分,我忽略了與廣告無關的所有其他內容。iOS - 如何設置LeadBolt中廣告的刷新率sdk
overlay = [[UIWebView alloc] initWithFrame:CGRectZero];
titleBar = [[UIToolbar alloc] initWithFrame:CGRectZero];
footerBar = [[UIToolbar alloc] initWithFrame:CGRectZero];
clickTitleBar = [[UIToolbar alloc] initWithFrame:CGRectZero];
clickFooterBar = [[UIToolbar alloc] initWithFrame:CGRectZero];
mask = [[UIView alloc] initWithFrame:CGRectZero];
[self.view insertSubview:mask atIndex:2];
[self.view insertSubview:clickTitleBar atIndex:3];
[self.view insertSubview:clickFooterBar atIndex:4];
[self.view insertSubview:titleBar atIndex:5];
[self.view insertSubview:footerBar atIndex:6];
[self.view insertSubview:overlay atIndex:7];
overlay.delegate = overlayController;
//initialize the overlayController
overlayController = [[LeadboltOverlay alloc] init];
[overlayController setSectionid:@"MY AD #"];
[overlayController setAdWebView:self.overlay];
[overlayController setCloseBar:self.titleBar];
[overlayController setFooterBar:self.footerBar];
[overlayController setClickCloseBar:self.clickTitleBar];
[overlayController setClickFooterBar:self.clickFooterBar];
[overlayController setLocationControl:@"0"];
[overlayController setMask:self.mask];
///////This part here?///////
[overlayController loadAd];
/////////////////////////////
overlay.delegate = overlayController;
self.stsTimer = [NSTimer timerWithTimeInterval:3.0 target:self selector:@selector(checkCompleted) userInfo:nil repeats:YES];
[[NSRunLoop currentRunLoop] addTimer:self.stsTimer forMode:NSDefaultRunLoopMode];