只需要在需要打開的activity標籤下添加intent-filter
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<category android:name="android.intent.category.DEFAULT" />
<!-- scheme是必須的,其他的不必須 -->
<data
android:scheme="xiaohouzi"
android:host="hou"
android:sspPrefix="/123"
android:port=""
/>
</intent-filter>
html頁面中需要超鏈接地址
<a href="xiaohouzi://hou/123">點擊打開應用</a>
這樣點擊打開應用時就會跳到註冊了的activity