Skip to content

Instantly share code, notes, and snippets.

@archugs
Last active August 29, 2015 14:12
Angular.js ngDialog example
var app = angular.module('demo', ['ngDialog']);
app.controller('MainCtrl', function ($scope, ngDialog) {
$scope.openContactForm = function() {
ngDialog.openConfirm({template: 'contact_us.html',
scope: $scope //Pass the scope object if you need to access in the template
}).then(
function(value) {
//save the contact form
},
function(value) {
//Cancel or do nothing
}
);
};
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment