WEB DEVELOPER SITE
TUTORIALS HTMLCSSJAVASCRIPTSQLPHPBOOTSTRAPJQUERYANGULARXML


 

Cordova InAppBrowser


The Cordova InAppBrowser plugin is employed to open external links from your app within an internet browser read.

Using Browser

It is terribly simple to begin operating with this plugin. All you wish to try and do is to open the electronic communication window and install the Cordova plugin.

C:\Users\Username\Desktop\MyApp>cordova plugin add org.apache.cordova.inappbrowser

HTML Code

<button class = "button" ng-click = "openBrowser()">OPEN BROWSER</button>

Controller Code

.controller('MyCtrl', function($scope, $cordovaInAppBrowser) {
   var options = {
      location: 'yes',
      clearcache: 'yes',
      toolbar: 'no'
   };
   
   $scope.openBrowser = function() {
      $cordovaInAppBrowser.open('http://ngcordova.com', '_blank', options)
		
      .then(function(event) {
         // success
      })
		
      .catch(function(event) {
         // error
      });
   }
})

When the user taps the button the InAppBrowser will open the URL we provided.

Ionic Cordova InAppBrowser Several different ways square measure typically used with this plugin, variety of that square measure at intervals the subsequent table.

Welookups is optimized for learning.Copyright 2018 - 2019 kumar aditya singh .
All Right Reserved and you agree to have read and accepted our term and condition.
All Rights Reserved.

welookups.comJavacodegeeks