- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am using an Ionic popup and I want to open it using only javascript.
I was able to open it using button:
<button ng-controller="uib_w_69_popup_controller" ng-click="show()" class="button widget uib_w_28 d-margins " data-uib="ionic/button" data-ver="0" id="site-1">Button Name</button>
Now how do I open it using only javascript?
Here is the js for the popup:
function uib_w_69_popup_controller($scope, $ionicPopup) { // A confirm dialog $scope.show = function() { var confirmPopup = $ionicPopup.confirm({ title: 'Consume Ice Cream', template: 'Are you sure you want to eat this ice cream?' }); confirmPopup.then(function(res) { if(res) { console.log('You are sure'); } else { console.log('You are not sure'); } }); }; };
Thanks for your help
- Tags:
- HTML5
- Intel® XDK
Link Copied
0 Replies
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page