这是我的logcat回复
05-25 06:32:45.552: I/Ads(408): onFailedToReceiveAd(Ad request successful, but no ad returned due to lack of ad inventory.)
05-25 06:43:37.802: I/Ads(408): adRequestUrlHtml: <html><head><script src="http://media.admob.com/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"kw":[],"preqs":4,"session_id":"11876839087358837237","u_sd":1.5,"seq_num":"5","slotname":"MY_AD_UNIT_ID","u_w":533,"msid":"oriental.orientalDaily","simulator":1,"cap":"a","adtest":"on","js":"afma-sdk-a-v6.0.0","isu":"B3EEABB8EE11C2BE770B684D95219ECB","cipa":0,"format":"320x50_mb","net":"ed","app_name":"2.android.oriental.orientalDaily","hl":"en","u_h":853,"carrier":"310260","ptime":680039,"u_audio":4});</script></head><body></body></html>
05-25 06:43:37.952: I/Ads(408): To get test ads on this device, call adRequest.addTestDevice(AdRequest.TEST_EMULATOR);
05-25 06:43:38.002: I/Ads(408): adRequestUrlHtml: <html><head><script src="http://media.admob.com/sdk-core-v40.js"></script><script>AFMA_buildAdURL({"preqs":5,"session_id":"11876839087358837237","u_sd":1.5,"seq_num":"6","slotname":"a14fb2149ab3ccb","u_w":533,"msid":"oriental.orientalDaily","simulator":1,"cap":"a","js":"afma-sdk-a-v6.0.0","isu":"B3EEABB8EE11C2BE770B684D95219ECB","cipa":0,"format":"320x50_mb","net":"ed","app_name":"2.android.oriental.orientalDaily","hl":"en","u_h":853,"carrier":"310260","ptime":680229,"u_audio":4});</script></head><body></body></html>
05-25 06:43:39.202: I/dalvikvm(408): Jit: resizing JitTable from 1024 to 2048
05-25 06:43:39.993: W/webcore(408): Can't get the viewWidth after the first layout
05-25 06:43:42.372: W/webcore(408): Can't get the viewWidth after the first layout
05-25 06:43:42.405: W/Ads(408): Invalid unknown request error: Cannot determine request type. Is your ad unit id correct?
05-25 06:43:42.405: D/webviewglue(408): nativeDestroy view: 0x4e5768
05-25 06:43:42.412: I/Ads(408): onFailedToReceiveAd(Invalid Ad request.)
05-25 06:43:42.672: I/Ads(408): Received ad url: <url: "http://googleads.g.doubleclick.net:80/mads/gma?preqs=5&session_id=11876839087358837237&u_sd=1.5&slotname=a14fb2149ab3ccb&u_w=533&msid=oriental.orientalDaily&cap=a&js=afma-sdk-a-v6.0.0&isu=B3EEABB8EE11C2BE770B684D95219ECB&cipa=0&format=320x50_mb&net=ed&app_name=2.android.oriental.orientalDaily&hl=en&u_h=853&carrier=310260&ptime=680229&u_audio=4&u_so=p&output=html®ion=mobile_app&u_tz=0&ex=1&client_sdk=1&askip=0&caps=interactiveVideo_clickTracking_sdkAdmobApiForAds&jsv=24" type: "admob" afmaNotifyDt: "null">
05-25 06:43:43.044: D/webviewglue(408): nativeDestroy view: 0x4cc800
05-25 06:43:43.044: I/Ads(408): onFailedToReceiveAd(Ad request successful, but no ad returned due to lack of ad inventory.)
没有错误,但没有在星系说明中显示,但其他设备可以显示。
有什么问题?
答案 0 :(得分:0)
从日志中,看起来你正在提出两个请求,这有点奇怪。无论如何,您的第一个请求无效,因为您需要指定发布商ID替换MY_AD_UNIT_ID
。