I have Android game project and I'm using ad-mob for ads. But, how to make if someone wants to remove ads must pay first.
Can you give me the tutorial, as I'm a newbie in Android and Java
Google is now letting Web users pay a monthly fee to remove ads from sites. The subscription service, called Google Contributor, asks users to pay $1 to $3 a month to remove advertising from partner sites on both desktop and mobile.
Select “In-App Purchases.” Turn off your phone's in-app purchases by selecting “Don't Allow.” And you're all set. Remember to get an App Store refund for any purchases you regret making.
In-app purchases allow developers to offer the app for free in the App Store (for iOS) and Google Play (for Android). Then, within the application, they can upsell and advertise paid upgrades, locked features, special items, and other premium offers.
Go to your Google Play Developer Console -> Choose your app -> Click In-app Products -> Click on the in-app product and change it from active to inactive.
You can simply make a button to make in-app purchase in your application. And, once the user presses the button, starts the in-app process, and removes the ads.
Make a flag. It can be in your shared preferences
and can be marked true on successful in-app purchase.
Once the purchase is done on all places where the ad is displayed, check the flag, and if it's false then don't display ad.
Follow this link: Integrating Google Play In-app Billing into an Android Application
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With