bootstrap的模态弹窗 和CKEditor的模态弹窗冲突问题解决

今天药忘吃喽~ 2022-07-13 05:43 313阅读 0赞

哪个页面有问题就在哪个页面加上如下js代码:

$.fn.modal.Constructor.prototype.enforceFocus = function () {
modal_this = this
$(document).on(‘focusin.modal’, function (e) {
if (modal_this.$element[0] !== e.target
&& !modal_this.$element.has(e.target).length
&& !$(e.target.parentNode).hasClass(‘cke_dialog_ui_input_select’)
&& !$(e.target.parentNode).hasClass(‘cke_dialog_ui_input_text’)) {
modal_this.$element.focus()
}
})
};

发表评论

表情:
评论列表 (有 0 条评论,313人围观)

还没有评论,来说两句吧...

相关阅读

    相关

    模态窗 开发工具与关键技术:Visual Studio 2015 – 模态窗 作者:廖亚星 撰写时间:2019年 5月 25 日 在搭建页面的时候,往往会弹