I can't launch the application from javascript to URL scheme on Chrome on Android device.

Asked 1 years ago, Updated 1 years ago, 91 views

I'm running a URL scheme from php to javascript to launch the Android app.
The app won't start.The application starts without any problems with browsers such as OPERA.
I am at a loss because I cannot figure out the cause, whether it is Chrome's setting or javascript problem.
I think there is no problem on the app side because OPERA and so on will start.
Please let me know if you know anything.

The following is the source of php:

<?php

echo<<EOM
<script type="text/javascript">
  window.location.href='appscheme://';
</script>
EOM;

?>

javascript php android google-chrome

2022-09-30 15:42

1 Answers

It must be in the intent://~ format to invoke over the link.
https://developer.chrome.com/docs/multidevice/android/intents/

intent:  
   HOST/URI-path//Optional host  
   #Intent;  
      package=[string];  
      action=[string];  
      category=[string];  
      component=[string];  
      scheme=[string];  
   end;


2022-09-30 15:42

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.