Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
302 views
in Technique[技术] by (71.8m points)

android - how to add google admob ad in flash for ios?

I am try to add admob ad to my flash for ios application.I have install the admob ane(https://code.google.com/p/flash-air-admob-ane-for-ios-and-android/) add the follow code in timeline

import so.cuo.platform.admob.Admob; 
import so.cuo.platform.admob.AdmobEvent; 
import so.cuo.platform.admob.AdmobSize; 
var admob:Admob=Admob.getInstance(); 
admob.setKeys("ca-app-pub-17380930385764784/6322941144","ca-app-pub-17380930385764874/4846207943"); 
admob.showBanner(Admob.BANNER,AdmobPosition.BOTTOM_CENTER);

and the content of test-app.xml

<?xml version="1.0" encoding="utf-8" standalone="no"?>
<application xmlns="http://ns.adobe.com/air/application/14.0">
    <id>test</id>
    <filename>test</filename>
    <name>test</name>
    <versionNumber>1.0.0</versionNumber>
    <initialWindow>
        <content>test.swf</content>
    <autoOrients>false</autoOrients>
        <fullScreen>false</fullScreen>
        <visible>false</visible>
    </initialWindow>
<android>
        <manifestAdditions><![CDATA[
            <manifest android:installLocation="auto">

                <uses-permission android:name="android.permission.INTERNET"/>

                <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
                <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
                 <application>
                <meta-data
            android:name="com.google.android.gms.version"
            android:value="@integer/google_play_services_version" />
                        <activity
            android:name="com.google.android.gms.ads.AdActivity"
            android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>
                </application>
            </manifest>

        ]]></manifestAdditions>
    </android>
    <iPhone>
        <InfoAdditions><![CDATA[
            <key>UIDeviceFamily</key>
            <array>
                <string>1</string>
                <string>2</string>
            </array>
        ]]></InfoAdditions>
        <requestedDisplayResolution>high</requestedDisplayResolution>
    </iPhone>
</application>

but get a error when I run.

invalid application descriptor unknown namespace http //ns.adobe.com/air/application/14.0

I do not know what step cuased this.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

AIR SDK version is too low. Upgrade adobe flash AIR SDK to version 14 or later.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...