从url打开Activity不能正常工作

时间:2016-01-22 07:57:40

标签: android deep-linking

朋友们,我想在浏览器中调用特定类型的网址时打开我的应用程序(预定义格式)

以下是服务器上的溃败

Redirect::to('intent://com.customlymade.activit/#Intent;scheme=customlymade;package=com.customlymade.activity;end');

以下是我在清单文件中使用的intent过滤器

<intent-filter>
    <data
        android:host="com.customlymade.activity"
        android:scheme="customlymade" />

    <action android:name="android.intent.action.VIEW" />

    <category android:name="android.intent.category.BROWSABLE" />
    <category android:name="android.intent.category.DEFAULT" />
</intent-filter>

但没有什么工作请帮助。

1 个答案:

答案 0 :(得分:1)

我猜,重定向是自动执行的。 Android中的Chrome具有安全功能,启动活动只能在用户操作后完成(如点击链接)。参见&#34;参见&#34;在https://developer.chrome.com/multidevice/android/intents

  

在以下情况下,Chrome不会针对给定的Intent URI启动外部应用。

     
      
  • 从输入的URL重定向Intent URI时。
  •   
  • 在没有用户手势的情况下启动Intent URI。
  •