Madserve SDK android: Display Interstitial ad at center and adding close button to in

940 views Asked by At

If anyone used Madserve SDk for android then do suggest answer. I am using open source madserver SDK for android devices, Which Fetch ad from madserver host. Its an open source project but no one is replying on its form or github. I stuck in SDK to display full screen interstitial ads at center. It is displayed on top left corner.

-Thanks

1

There are 1 answers

0
Vaibhav Dhage On BEST ANSWER

In Madserve SDK the ad is displayed within the webview so the ad is content inside Webview and even centering webview content will be always displayed as it is Loaded(for large screen devices at Left corner).

So I have used some CSS tricks to position the ad at center, where we add code for Image Banner in Madserve I added Following CSS code in HTML banner code to make it display always at center,

.className {
    max-width: 100%;
    max-height: 100%;
    bottom: 0;
    left: 0;
    margin: auto;
    overflow: auto;
    position: fixed;
    right: 0;
    top: 0;
}

This will position the ad at center, This Fixed my issue for now, I'll look in the SDK where webview is Created and try to display whatever content we get at the center .