Reputation: 191
I'm using the YouTubePlayerFragment to show YouTube videos on Android and the ads that are associated with them, but I have observed some wierd behaviour.
It used to work fine on several devices (ads appeared) but not on others : the video player would work fine to play/pause video, but ads would never appear.
Today, after building and debugging the same code, I noticed that the ads that used to appear on my device do not appear anymore! And my code hasn't changed...
Do you have any idea what this could be linked to? Could this be linked to the developer API key I am using for development (limited number of requests for a certain device)?
Cheers
Upvotes: 0
Views: 1056
Reputation: 4037
It is not in the control of developer whether the ads have to be shown or not. It is in control of the content owner of that video, developer is just using the API to fetch the video. This issue is not related to the device or YouTube API or the API key.
If you are the content owner of the YouTube videos that are been displayed on your YouTube Player via YouTubePlayerFragment then one thing you could have done is to upload copies in your own account, and then ensured that your account was set up with monetization turned off, then that would prevent ads from showing during playback. It's up to you to work out that arrangement/permission with the original videos' owners. But since you have not mentioned any of this I am assuming its just the behavior that is intermittent. You will be able to see ads after a while.
Upvotes: 1