(function($) { var Confirm = function(element, options) { this.$element = $(element); this.options = $.extend({}, $.fn.confirm.defaults, options); this.$element.click($.proxy(this.show, this)); }; Confirm.prototype = { constructor: Confirm, show: function(e) { e.preventDefault(); this.box = this.buildbox(); this.box.modal(); this.box.on('hidden', $.proxy(this.hidden_callback, this)); }, buildcheckboxes: function() { var result = ""; if (!this.options.checkboxes) { return ""; } result = '
'; return result; }, buildbox: function() { var box = $('', { id: "confirmbox", 'class': "modal" }); box.append($('' + this.buildcheckboxes() + '