7 Replies Latest reply on Aug 22, 2016 8:59 PM by arviio

    Phonegap builded Android app didnt open external links

    JokerzFree

      Hello! Try to open external links into my android app but all methods in google and forum not working. Use latest Phonegap version (6.3.0), Jquery Mobile (1.4.5) and InAppBrowser (1.4.0), there is my code:

       

      Config.XML

          <plugin name="cordova-plugin-inappbrowser" spec="1.4.0" />
          <access origin="*" browserOnly="true"/>
          <allow-intent href="http://*/*" />
          <allow-intent href="https://*/*" />
          <allow-intent href="tel:*" />
          <allow-intent href="sms:*" />
          <allow-intent href="mailto:*" />
          <allow-intent href="geo:*" />
          <preference name="stay-in-webview" value="false" />
      

       

      Index.HTML

      fbe.grsu.by


      JavaScript

       

          $(document).on('tap', 'a[href^="http://"], a[href^="https://"]', function(e){
              e.preventDefault();
              $this = $(this);
              cordova.InAppBrowser.open($this.attr('href'),'_system');,
          });
      

       

      What i try: all '_system', '_blank', 'self' with different methods (like window.open, cordova.InAppBrowser and etc), simple links and deviceready listeners (with windows.open = cordova.InAppBrowser), different configs in config.xml and many many more methods. But no one didnt work, links just not opened at all.
      HELP!


      Best Regards.