How to place the MEDIUM_RECTANGLE banner ad into content
See original GitHub issueTried to place the MEDIUM_RECTANGLE Banner ad into my code and It is showing smart banner ad and its comming into center place
i am using IONIC Capacitor
const showTabBarBanner = () => {
const options: AdOptions = {
adId: 'ca-app-pub-XXX/XXX',
adSize: AdSize.MEDIUM_RECTANGLE,
position: AdPosition.CENTER,
};
// Show Banner Ad
AdMob.showBanner(options)
.then(
async (value: any) => {
await Toast.show({
text: ''
})
},
(error: any) => {
console.error(error); // show error
}
);
// Subscibe Banner Event Listener
AdMob.addListener('onAdLoaded', async (info: boolean) => {
console.log('Showing TabBar Banner AD.');
});
}
I want to show 300x250 ad into my content. can you please help me on this.
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Banner ad guidance: 300x250 - Google AdMob Help
The 300x250 ad is the IAB medium rectangle that is available for both phones and ... This includes placing the ad over a...
Read more >Banner Ads - Meta for Developers - Facebook
A banner is a small bar ad that appears at the bottom or top of your content. Banner ads usually measure 320 x...
Read more >Medium Rectangle Ads [MREC]
MREC advertising best practices Place MREC ads at natural points: To see high levels of engagement, place your MREC ads at high visibility...
Read more >Medium Rectangle Ads – A Flexible Monetization Tool For ...
Medium rectangle ads are medium-format ad units sized between mobile banners and full-screen interstitials. At this scale, advertisers can include more details ...
Read more >MPU (300x250)
It is commonly called a 300×250 or MPU but is also known as a Med Rec, MREC, or Medium Rectangle. MPUs are the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This can not be done with the current implementation and in general it will be really hard to implement since what we see in those Screenshots are native ads.
In theory, and I will talk about android that is what I know, you could register some event attached to a div in the web view that sends the position to the native part, and ask the native part to move the View into that place.
There we could have problems like lag so the ad is placed above the content until the Javascript thread is free and can send the event.
Another problem is how do you scrolls it outside the screen and manages how it returns to it. Androids uses a
RecyclerView
element to manage that and prevent memory leaks. We can not use that so we should create some kind of webview recycler view handling mechanism that would be really prone to memory leaks.So again, that is not posible right now but we are always open and glad to get PRs.
Thanks for the issue. I don’t see any more questions, so I’ll close this one.