5

I will like to open an app if the url

for example if the person opens : http://www.example.com/id=100, i would like to parse example.com and show options to open it with my app.

The same functionality is used by youtube, if you click on youtube link it will either ask if you would like to open it using youtube or directly play youtube video

1
  • Use an intent. The answer by Nirav should work for you. Commented Jan 30, 2013 at 5:40

2 Answers 2

7

You can add a data specification to your intent filter with the http schema and the domain you want to open with your app.

<intent-filter ... >
    <data android:scheme="http" android:host="example.com" />
    ...
</intent-filter>
Sign up to request clarification or add additional context in comments.

1 Comment

Umh, that line up there is the snippet from the manifest file.
1
Intent LaunchIntent = getPackageManager().getLaunchIntentForPackage("com.package.address");
startActivity(LaunchIntent);

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.