android - Launch app from URL containing question mark -
i know how deal urls such as: http://example.com/xyz. however, url contains question mark follows: https://example.com/?xyz
so when getintent().getdata().getpath() output /. question marking somehow limiting processing. how deal it?
here intent-filter in manifest:
<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="example.com" android:scheme="https"></data> </intent-filter> here code activity:
if (getintent() != null && data != null && data.getpathsegments().size() >= 1) { log.d("tagit", getintent().getdata().getpath().tostring()); } now, log shows blank.
well, got working getting complete link using following:
data.getencodedschemespecificpart(); thanks answer: https://stackoverflow.com/a/25295636/3739412
Comments
Post a Comment