简体   繁体   English

应用链接无法在移动浏览器中使用Intent

[英]App Link is not working in mobile browser using intent

I am trying to open app(digital wallet app) directly from web browser (if it is a mobile). 我正在尝试直接从网络浏览器 (如果是移动设备) 打开应用程序(数字钱包应用程序 )。

I already referred the following links 我已经提到了以下链接

Make a link in the Android browser start up my app? 在Android浏览器中建立链接以启动我的应用程序吗?

Launch custom android application from android browser 从android浏览器启动自定义android应用程序

For your information i am working on integrating payment gateway(digital wallet) in my website which has a payment type like QR code(scan and pay) and another one is deep app link , so what i am implementing is, if website then payment type will be QR code (already implemented) but if it is mobile it will be deep app link (provided by digital wallet payment gateway). 为了您的信息,我正在将付款网关(数字钱包)集成到我的网站中,该网站的付款类型如QR码(扫描并付款),而另一个是深层应用链接 ,所以我要实现的是,如果网站是付款类型将是QR码 (已实现),但如果是移动设备,它将是深层应用程序链接 (由数字钱包付款网关提供)。

Here is the intent filter available in manifest.xml file, but i can't edit that(as that app is from third party). 这是manifest.xml文件中可用的意图过滤器,但我无法对其进行编辑(因为该应用程序来自第三方)。

在此处输入图片说明

My intention is If the user visit from mobile browser and make a payment in my website? 我的意图是,如果用户通过移动浏览器访问并在我的网站上付款? then i want to redirect to the digital wallet app using deep link(provided by the payment gateway) to complete the payment. 然后我想使用深层链接(由付款网关提供)重定向到数字钱包应用程序以完成付款。

This is the deep link provided in halalah digital wallet payment gateway https://halalah.sa/wp-content/uploads/2018/12/HalalaH-Deep-Linking-Guide.pdf 这是Halalah数字钱包支付网关https://halalah.sa/wp-content/uploads/2018/12/HalalaH-Deep-Linking-Guide.pdf中提供的深层链接

halalahewallet://transaction?terminal=HG00001&amount=0.02&referenceNo=london50&billNo=london123&memo=memo halalahewallet://交易终端= HG00001&量= 0.02&referenceNo = london50&billNo = london123&备忘录=备忘录

so for that i tried the following code as a link 所以为此,我尝试了以下代码作为链接

<a href="intent://transaction?terminal=HG00001&amount=0.01&referenceNo=london501&billNo=london1231&memo=memo#Intent;scheme=halalahewallet;package=sa.halalah.halalah;end">Pay using App</a>

while i test this above code that parameter value is not take it into action(hence app is not launch to perform payment, instead it goes to their play store page), though i installed and configured that app in my side. 尽管我在上面的代码中测试了该参数值,但我没有安装并配置该应用程序,但该参数值并未付诸行动(因此,该应用程序不会启动以执行付款,而是转到其Play商店页面)。

I checked using deep link tester app ( https://play.google.com/store/apps/details?id=com.manoj.dlt&hl=en ) with above deep link uri - it launch website without any issue, i guess the problem is happen from web browser or from my above tried intent code? 我使用带有上述深层链接uri的深层链接测试器应用程序( https://play.google.com/store/apps/details?id=com.manoj.dlt&hl=en )检查-它启动网站没有任何问题,我想问题是从网络浏览器发生还是从我上面尝试过的意图代码发生? i want to launch that app from browser directly with required parameters to perform payment. 我想直接使用所需参数从浏览器启动该应用程序以执行付款。

Try to add target="_blank" in the a tag 尝试在a标签中添加target =“ _ blank”

<a target="_blank" id="deepLink" href="HalalaHeWallet://Transaction?terminal=HG00001&amount=0.02&referenceNo=refNumber&billNo=billNumber&memo=memo&callback=slack://open" class="btn btn-primary btn-block mt-2 ">pay throw Halalah App</a>

and for more information about Halalah integration check this link: https://github.com/halalah/HalalaH-Integration-Guides 有关Halalah集成的更多信息,请检查此链接: https : //github.com/halalah/HalalaH-Integration-Guides

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM