如何启动应用程序 [英] How to make launch of application

查看:132
本文介绍了如何启动应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在开发一个应用程序,我要做的是第一个用户将从我的应用程序注册,注册成功后,一个确认链接将进入gmail,如果用户单击确认链接,则从该邮件中获取我应用程序应该打开,可以吗?有人可以帮我吗?

I am working on one application,What i am trying to do is first user will register from my app,after successful registration,one confirmation link will get in gmail,now from that mail if user will click on confirmation link,my app should open,Is it possible? can any one help me with that?

推荐答案

您必须对清单进行一些更改.在启动器或默认活动中进行如下更改:

you must do some changes your manifest. Do changes in launcher or default activity like below:

 <activity
        android:name=".MainActivity"
        android:configChanges="keyboardHidden|orientation|keyboard|screenSize"
        android:windowSoftInputMode="stateHidden">
        <intent-filter>
            <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.BROWSABLE" />
            <category android:name="android.intent.category.DEFAULT" />

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

可浏览和数据标签可以为您提供帮助.

BROWSABLE and data tags help you.

这篇关于如何启动应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆