本文介绍了这是个好主意,发布一个应用程序时,删除测试设备ID为AdMob的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我是preparing推出Play商店的应用程序,并与AdMob的实验(在测试模式下与我的设备ID)后,我现在不知道我是否应该删除测试设备ID,只留下该TEST_EMULATOR。
I'm preparing to launch an app in the Play Store, and after experimenting with AdMob (in test mode with my device id), I am now wondering if I should remove the test device id, and leave only the TEST_EMULATOR.
你觉得,有必要吗?
推荐答案
是的,你应该发布之前删除测试模式:
Yes you should remove test mode before publishing:
AdView adView = (AdView) findViewById(R.id.ad);
AdRequest adRequest = new AdRequest();
adView.loadAd(adRequest);
在的onDestroy(): adView.destroy();
In onDestroy(): adView.destroy();
在布局:
<com.google.ads.AdView
android:id="@+id/ad"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
ads:adSize="BANNER"
ads:adUnitId="@string/admob_publisher_id"
ads:loadAdOnCreate="true" >
</com.google.ads.AdView>
在AdMob的应用程序设置中选择这样的:停用测试模式为所有请求
In AdMob app settings select this: Disable test mode for all requests
这篇关于这是个好主意,发布一个应用程序时,删除测试设备ID为AdMob的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!