사용자가 특정 URL을 탐색 할 때 응용 프로그램을 시작하려고합니다. 나는 몇 가지 예를 발견했으며 그들은 모두 매니 페스트에서 동일한 것들을 가지고 있지만 그것은 나를 위해 일하지 않습니다. 나는 인 텐트 필터를 리시버뿐만 아니라 액티비티 밑에 두었다. 활동에 따라, 나는 onNewIntent을 사용하고 리시버에서 때, 나는 onReceiveIntent를 사용하여 시도했을 때, 간단한 Log.i 호출로 둘 경우 URL에서 활동 시작
<intent-filter>
<action android:name="android.intent.action.VIEW"></action>
<category android:name="android.intent.category.DEFAULT"></category>
<category android:name="android.intent.category.BROWSABLE"></category>
<data android:host="www.urbandictionary.com" android:scheme="http"></data>
</intent-filter>
볼 수
: 여기 내 매니페스트 조각입니다 해고 됐는지 아닌지. 나는 운이별로 없다.
관련 질문 :이 방법을 사용 http://stackoverflow.com/questions/2448213/how-to-implement-my-very-own-uri-schema-on-android – Casebash