I have an Ionic Cordova app for android which has a button to facebook messenger:
<a href="https://m.me/my-fb-page" target="_blank"><img src="assets/images/messenger.svg" /></a>
When tapped, nothing appears on the screen. I keep receiving this error through logcat:
CordovaWebViewImpl: Blocked (possibly sub-frame) navigation to non-allowed URL: intent://user/xxxxxxxxxxxxx/?intent_trigger=mme&nav=discover#Intent;scheme=fb-messenger;package=com.facebook.orca;end
I have cordova-plugin-whitelist installed.
Content of config.xml:
...
<content src="index.html" />
<access origin="*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
<allow-navigation href="*" />
<allow-intent href="tel:*" />
<allow-intent href="sms:*" />
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<allow-intent href="fb-messenger:*" />
<platform name="android">
<allow-intent href="market:*" />
<allow-intent href="fb-messenger:*" />
...
I have tried a number of options for allow-intent, access and allow navigation.
The issue is not specifically related to facebook messenger, I have problems with opening other external (payment) apps as well
With <allow-navigation href="*" />
you are telling your app to navigate to every url, that prevents any allow-intent
from working as it will try to navigate to it instead of launching the intent.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With