Receive URL in Ionic/Cordova

孤街浪徒 提交于 2019-12-02 22:20:20

I've been working on something similar. I was able to get the url by using this plugin by Initsogar

The plugin can be found here https://github.com/Initsogar/cordova-webintent

You can get the incoming url as follows:

var incomingURL
window.plugins.webintent.getExtra(window.plugins.webintent.EXTRA_TEXT,
      function(url) {
        incomingURL = url
        console.log(incomingURL);
      }, function() {
        incomingURL = false;
      }
  );

Hope this helps, and good luck on the app! Ionic is awesome :)

For general help and recent developments I want to add an answer to this.

There is a cordova plugin called Custom URL scheme. For the documentation of plugin is solid I don't add any further information.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!