什么是“行动机器人:名字=" com.android.vending.INSTALL_REFERRER" '? [英] What is 'action android:name="com.android.vending.INSTALL_REFERRER" '?
问题描述
我已经测试了Appbrain SDK和SDK的InMobi。
而且我发现这个共同的接收器。和我做了自定义的接收器。
我认为,当下载在谷歌电子市场应用程序,谷歌电子市场发送引荐的价值我的应用程序。但是,我还没有收到任何东西。什么问题?
I had tested the Appbrain SDK and Inmobi SDK. And I found this common receiver. And I made custom receiver. I thought that when download the app in google market, google market sends 'referer' value to my app. But I haven't received anything. What's problem?
//This is Appbrain's receiver
<receiver android:exported="true" android:name="com.appbrain.ReferrerReceiver" >
<intent-filter>
<action android:name="com.android.vending.INSTALL_REFERRER" />
</intent-filter>
</receiver>
//This is Inmobi's receiver
<receiver android:name="com.inmobi.adtracker.androidsdk.IMAdTrackerInstallRefererReciever" android:exported="true" >
<intent-filter>
<action android:name="com.android.vending.INSTALL_REFERRER" />
<action android:name="android.net.conn.CONNECTIVITY_CHANGE" />
</intent-filter>
</receiver>
//This is My Custom receiver
<receiver android:name="com.xgame.adproject2.TestReceiver" android:exported="true" >
<intent-filter>
<action android:name="com.android.vending.INSTALL_REFERRER" />
</intent-filter>
</receiver>
// source
public class TestReceiver extends BroadcastReceiver{
public static final String TAG = "TEST";
String referrerString = "";
@Override
public final void onReceive(Context context, Intent intent) {
Log.e(TAG, "11111111");
if(intent.getAction().equals("com.android.vending.INSTALL_REFERRER")) {
Bundle extras = intent.getExtras();
referrerString = extras.getString("referrer");
Log.e(TAG, "REFERRER: " + referrerString);
}
}
}
在了应用,我输入的网址,Android的网页浏览器。但下载的应用程序后,我还没有收到引用值。
When down the app, I was input this url in android web browser. But after download app, I haven't received referrer value.
<一个href=\"https://play.google.com/store/apps/details?id=com.xgame.adproject2&referrer=utm_source%3Dcom.xgame.adproject2%26utm_medium%3Dgoogle%26utm_term%3Dbanner%26utm_campaign%3Dxgame\" rel=\"nofollow\">https://play.google.com/store/apps/details?id=com.xgame.adproject2&referrer=utm_source%3Dcom.xgame.adproject2%26utm_medium%3Dgoogle%26utm_term%3Dbanner%26utm_campaign%3Dxgame
推荐答案
一个很久以前Android市场会通过你的市场页面的来源字符串,导致你的安装。在某些时候,谷歌停止了这一点。
您可以在 http://productforums.google.com看到这一个线程/论坛/#!话题/ Android的市场/ F5TO9uE3WSA
A long time ago the Android market would pass you a referrer string of the market page that led to your install. At some point Google stopped this. You can see a thread on this at http://productforums.google.com/forum/#!topic/android-market/F5TO9uE3WSA
现在你只有当你明确地传递是市场应用打开时,它的引用字符串。例如,如果一个应用程序有一个按钮来安装应用程序B,你可以传递一个引用字符串
市场://细节ID = B和引荐= A?这是非常有用多为希望来衡量广告的应用程序的有效性广告网络
Now you get the referrer string only if you explicitly pass is to the market app when opening it. For example if app A has a button to install app B, you can pass a referrer string market://details?id=B&referrer=A. It's useful mostly for ad network that want to measure the effectivity of ads for apps
这篇关于什么是“行动机器人:名字=&QUOT; com.android.vending.INSTALL_REFERRER&QUOT; '?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!