I am testing the AdMob for Android SDK. I can't set the admob:testing="true"
because the admob attribute is unknown.
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:admob="http://schemas.android.com/apk/res/org.ifies.android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="#FF000000"
android:clickable="true"
>
<com.admob.android.ads.AdView
android:id="@+id/admob"
android:visibility="visible"
android:layout_width="fill_parent"
android:layout_height="100px"
android:background="#FF0000"
admob:testing="true"
/>
</LinearLayout>
My Eclipse is complaining that admob:testing="true"
would have an unknown prefix. Anyone got an idea on how to fix this?
Sub question: Anyone got an idea how to change the height of the ad? It seems to be fixed to 48px, which is not looking good on any DROID phone...
Might be worth checking that the error isn't due to something outside the file:
Make sure the package name you are using in your schema URI, "org.ifies.android", matches the value of the package attribute on the manifest element in AndroidManifest.xml.
Make sure res/values/attrs.xml has the attributes specified:
This took me a while to figure out, so I am posting it here:
Since AdMob 4.1 this has changed, so the previous answer is correct for versions <=4.04. Now you need to use:
No place for your own package in the new schema and no need for an attrs.xml file.
Details here: http://groups.google.com/group/google-admob-ads-sdk/browse_thread/thread/3b885d3fe5bb21a5?pli=1 (Tim's post, it's the 8th from the top)