如题,一个页面上有多个模态框,如何单独设置某个特定模态框的margin top?
我已这样修改了bootstrap.js,统一设置了模态框的margin top,现在只想为一个特殊的模态框设置一个不同于其它模态框的margin top值:
Modal.prototype.adjustDialog = function () {
… …
var $modal_dialog = $(this.$element[0]).find('.modal-dialog');
var m_top = 6;
$modal_dialog.css({'margin': m_top + '% auto'});
}
可以添加额外的
class
吧,在 CSS 中对这个class
添加额外样式