【发布时间】:2017-04-14 05:04:32
【问题描述】:
我正在我的应用程序中集成 facebook 广告。我已经创建了一个 palcement id 并将代码放入我的应用程序中。我使用了 facebook 受众网络 sdk。我应该包含 facebook sdk 吗?
我的代码也可以在两个选项卡的 viewpager 底部显示广告。
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:animateLayoutChanges="true">
<android.support.design.widget.AppBarLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/ThemeOverlay.AppCompat.Dark">
<android.support.v7.widget.Toolbar
android:id="@+id/toolbar"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
app:layout_scrollFlags="scroll|enterAlways"
app:popupTheme="@style/ThemeOverlay.AppCompat.Light">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Linkto.be"
android:textAppearance="@style/TextAppearance.AppCompat.Widget.ActionBar.Title"
android:gravity="center"/>
</android.support.v7.widget.Toolbar>
<android.support.design.widget.TabLayout
android:id="@+id/tabLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/accent"/>
</android.support.design.widget.AppBarLayout>
<android.support.v4.view.ViewPager
android:id="@+id/pager"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="15dp"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
/>
<LinearLayout
android:id="@+id/banner_container"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:orientation="horizontal"/>
</android.support.design.widget.CoordinatorLayout>
【问题讨论】:
标签: android facebook-audience-network