Skip to content

Instantly share code, notes, and snippets.

@vpodlesnyak
Created February 17, 2014 14:56
Show Gist options
  • Save vpodlesnyak/9052046 to your computer and use it in GitHub Desktop.
Save vpodlesnyak/9052046 to your computer and use it in GitHub Desktop.
Intent filter for URL capturing
Task: catch urls of type http://ХХХXviewster.com/movie/XXXXXX
Solution: activity with 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" />
<data android:host="*.viewster.com" />
<data android:host="viewster.com" />
<data android:pathPattern="/movie/.*" />
</intent-filter>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment