I want to open my application if the url is clicked .I made this href :
<a href="my.special.scheme://other/parameters/here" >open app</a>
in the manifest I did this :
<activity
android:name="com.tejarat.example.Urlchema"
android:label="#string/app_name" >
<intent-filter>
<data android:scheme="my.special.scheme" />
<action android:name="android.intent.action.VIEW" />
</intent-filter>
</activity>
the problem is from url ,When I click on it , it says not found and nothing happens .
Could you help me ? What am I doing wrong ?
Thanks
you can use like this it will work
<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.youtube.com" android:scheme="http"></data>
</intent-filter>
Try this code it's work for me
<a href='demo://www.abc.com/'>demo://www.abc.com/</a></body></html>
in the manifest
<activity android:name=".myActivity">
<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="demo"/>
</intent-filter>
</activity>
Related
I have converted my website into app and I use [https://app.sarkaribank.com][1] type of links to load in webview. I want to use deep linking. Below is my manifest.xml file.
<activity
android:name="com.sarkaribank.Activities.BottomActivity"
android:screenOrientation="portrait"
android:label="#string/app_name"
android:theme="#style/AppTheme.NoActionBar">
<intent-filter android:label="SarkariBank">
<action android:name="android.intent.action.VIEW"/>
<category android:name="android.intent.category.BROWSABLE"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:scheme="https"
android:host="app.sarkaribank.com"
android:pathPrefix="/*.*"/>
</intent-filter>
</activity>
I want that my app should open whenever someone clicks any of these kinds of link
https://app.mysitename.com
<activity>
<intent-filter android:autoVerify="true">
<action android:name="android.intent.action.VIEW"/>
<category android:name="android.intent.category.BROWSABLE"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:scheme="https" android:host="app.sarkaribank.com"/>
<data android:scheme="http" android:host="app.sarkaribank.com"/>
</intent-filter>
</activity>
https://developer.android.com/training/app-links/verify-site-associations.html
<activity
android:name=".ActivateActivity"
android:configChanges="orientation"
android:windowSoftInputMode="adjustPan">
<intent-filter >
<data android:host="www.testlink.com.qa" android:pathPrefix="/templates/home.aspx/" android:scheme="http"/>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
</intent-filter>
</activity>
this is my code....its not working when click the link (www.testlink.com.qa) from my email.
but it work when i call from another app using Uri.parse("http://www.testlink.com.qa/templates/home.aspx")
<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.testlink.com.qa" android:path="www.testlink.com.qa/templates/home.aspx" android:scheme="http"></data>
</intent-filter>
Email link http://www.testlink.com.qa/templates/home.aspx
I want to open my app's LoginActivity when click on a <a href="www.myhost.com"/> in some web in Chrome browser app. I have this code but it is not working:
<activity android:label="#string/app_name" android:launchMode="singleTask"
android:name=".activities.LoginActivity" android:screenOrientation="portrait"
android:windowSoftInputMode="stateVisible">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
<intent-filter>
<data android:scheme="http" android:host="myhost.com"/>
<category android:name="android.intent.category.DEFAULT"/>
<category android:name="android.intent.category.BROWSABLE"/>
<action android:name="android.intent.action.VIEW"/>
</intent-filter>
</activity>
What am I doing wrong?
Thanks.
You need to set it up like this :
<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:host="example.com"
android:pathPrefix="/someresource/"
android:scheme="http" />
<data
android:host="www.example.com"
android:pathPrefix="/someresource/"
android:scheme="http" />
</intent-filter>
Notice that in your case, you would need to use android:pathPrefix instead of android:path.
I want to launch an activity when a link is clicked on android browser.
I have followed the instructions provided by the link .
When I open the browser and click on the link, the play store is lauched.
This is my href code contained in the html page:
intent://scan/#Intent;scheme=test;package=com.exekon.appbrowser.MainActivity;end
this and this is the code in the manifest:
<activity
android:name=".MainActivity"
android:exported="true"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<data android:scheme="test" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.intent.category.BROWSABLE" />
</intent-filter>
</activity>
Can anyone proved me an example?
Thanks
Look at the zxing source code mentioned in the instructions you used:
<data android:scheme="test" android:host="scan" android:path="/"/>
check the scheme definition into the AndroidManifest.xml
<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="zxing" android:host="scan" android:path="/"/>
</intent-filter>
you must use something like:
<data android:scheme="test" android:host="scan" android:path="/"/>
I'm currently writing an Android App and it should open Files with the ending .meetme
Actually it should open them directly from Gmail, but I don't think that is possible.
This is the Code of my AndroidManifest.xml:
<activity android:name=".MeetingRequest" android:label="Meeting Request">
<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="file" />
<data android:mimeType="*/*" />
<data android:host="*" />
<data android:pathPattern=".*\\.meetme" />
</intent-filter>
</activity>
I've tried quite a few variations, if I open the file in Astro wit h a long click and open as text, my app shows up and can open it normally.
Would be grateful for any help.
Markus
After a lot of trial and error and reading nearly everything I could find, here's what finally worked for me:
<activity android:name=".DrawActivity"
android:screenOrientation="portrait"
android:label="#string/app_name">
<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"/>
<action android:name="android.intent.action.EDIT"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:pathPattern="*.snowdragon"/>
<data android:mimeType="text/snowdragon"/>
</intent-filter>
</activity>