2012-09-12 4 views
0
<intent-filter> 
    <action android:name="android.intent.action.VIEW" /> 
    <category android:name="android.intent.category.DEFAULT" /> 
    <category android:name="android.intent.category.BROWSABLE" /> 
    <data android:scheme="appname"/> 
</intent-filter> 

나는 그것을 시도했지만 어떤 링크를 클릭해도 브라우저 목록에 내 앱이 표시되지 않습니다. 무엇이 잘못 될 수 있습니까?Android에서 링크를 클릭하면 브라우저 목록에 내 앱을 표시하는 방법은 무엇입니까?

+0

당신이'안드로이드를 포함하여 봤어 : mimeType를 = "text/html과"'(예를 들어)은''요소? – Squonk

답변

3

사용이 필터 :

 <intent-filter> 
      <action android:name="android.intent.action.VIEW" /> 
      <category android:name="android.intent.category.DEFAULT" /> 
      <category android:name="android.intent.category.BROWSABLE" /> 
      <data android:scheme="http"/> 
     </intent-filter> 
+0

코드바 앱이 주어진 URL을 얻는 방법은 무엇입니까? – Daniel

관련 문제