0

I need to open my android app when a QR code is scanned.

In the QR Code there is a link with a js script that open up the app.

In my Android Manifest I have add the intent however, when I visit the page the browser does not load the app. What am I missing?

Android:

    <!-- Test for URL scheme -->
    <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="bbb" android:host="index"/>
    </intent-filter>
    <!-- End Test for URL scheme -->

Js (testLink.php)

<script>
   window.location = 'bbb://index';
</script>
SNos
  • 3,430
  • 5
  • 42
  • 92

1 Answers1

0

Try setting your window.location to intent://index#Intent;scheme=bbb;end

Ryan
  • 1,151
  • 5
  • 7
  • when I load the page with `window.location` in the android browser it does not do anything, it just reload the browser page. The app is not opening – SNos Oct 11 '16 at 22:52