大小固定的橫幅廣告
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
如果自動調整橫幅廣告不符合需求,Google Mobile Ads SDK 也支援固定大小的廣告。
下表列出標準橫幅大小。
尺寸以 dp 為單位 (寬 x 高) |
說明 |
適用裝置 |
AdSize 常數 |
320x50 |
橫幅廣告 |
手機和平板電腦 |
banner |
320x100 |
大型橫幅廣告 |
手機和平板電腦 |
largeBanner |
300x250 |
IAB 中矩形廣告 |
手機和平板電腦 |
mediumRectangle |
468x60 |
IAB 完整橫幅廣告 |
平板電腦 |
fullBanner |
728x90 |
IAB 超級橫幅廣告 |
平板電腦 |
leaderboard |
放置廣告的容器至少必須與橫幅一樣大。任何邊框間距都會縮減容器的實際可用空間。如果容器無法容納橫幅廣告,系統將不會顯示廣告,並會記錄下列警告:
W/Ads: Not enough space to show ad. Needs 320x50 dp, but only has 288x495 dp.
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-09-02 (世界標準時間)。
[null,null,["上次更新時間:2025-09-02 (世界標準時間)。"],[],["The Google Mobile Ads SDK offers fixed ad sizes as an alternative to adaptive banners. Standard banner sizes include 320x50 (banner), 320x100 (large banner), 300x250 (medium rectangle), 468x60 (full-size banner), and 728x90 (leaderboard), each with specific `AdSize` constants. The ad container must be at least as large as the banner size, considering any padding. If the container is too small, the ad will not be displayed, and a warning will be logged.\n"],null,[]]