xml - Android Admob banner display always front the page -
my banner adview display front screenshot.
my xml code is:
<relativelayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:ads="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:id="@+id/content_main" android:layout_width="match_parent" android:layout_height="match_parent" app:layout_behavior="@string/appbar_scrolling_view_behavior" tools:showin="@layout/app_bar_main"> <relativelayout android:id="@+id/fragmentreplace" android:layout_width="match_parent" android:layout_height="wrap_content"></relativelayout> <com.google.android.gms.ads.adview android:id="@+id/adview" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignparentbottom="true" android:layout_alignparentstart="true" android:layout_margintop="30dp" ads:adsize="smart_banner" ads:adunitid="@string/banner_ad_unit_id"></com.google.android.gms.ads.adview>
how can fix it?
thanks
add below code:
<com.google.android.gms.ads.adview xmlns:ads="http://schemas.android.com/apk/res-auto" android:id="@+id/adview" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignparentbottom="true" android:layout_alignparentleft="true" ads:loadadoncreate="true" app:adsize="banner" app:adunitid="@string/banner_ad_unit_id" > </com.google.android.gms.ads.adview>
what want fix.
Comments
Post a Comment