따로 html을 만들어 해당 http://~~ 클릭시 어플 실행을 해주려고 합니다.
그런데 redirect해서 어떻게 불러야 어플을 실행시킬수 있는지 모르겠네요....
도와 주시면 정말 감사드리겠습니다..( _ _ )
유튜브처럼 해보세요.
액티비티에 url을 걸어서 해당 url이 호출되면 액티비티가 받도록..
자바스크립트 새창 띄우기로 url 호출하면 액티비티가 받았던거 같기도 하고...
<activity android:name="WatchActivity">
<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"
android:host="www.youtube.com"
android:pathPrefix="/watch"/>
</intent-filter>
</activity>
그 방법에 대해서 자세히 설명해주실수 있는 지요?ㅜ.ㅜ
매니페스트 런처 부분에
<data
android:scheme="http"
android:host="www.youtube.com"
android:pathPrefix="/watch"/>
이러한 부분을 추가 시키긴 하였는데 그렇다면 인터넷에서 http://www.youtube.com/watch 이렇게 입력하면 되는 것인지요?
그리고 WatchActivity에 어떤식으로 구성을 해야하는지. 알려주시면 정말 감사드리겠습니다.
http://www.youtube.com/watch 이렇게 호출하는것 맞구요.
1. WatchActivity에서 첫 진입 액티비티를 실행시켜주셔도 되고
2. <intent-filter> 태그 부분을 런처 액티비티에 넣으시면 런처 액티비티가 바로 실행되겠죠.
첫 진입 액티비티가 Main이면
런처 인텐트 필터 다음에 추가하시면 됩니다.
<activity android:name="Main">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<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"
android:host="www.youtube.com"
android:pathPrefix="/watch"/>
</intent-filter>
</activity>




c2dm으로 처리해야 하지 않을까요...