doonbfez815298 2016-03-03 06:04
浏览 46
已采纳

在模式对话框中,CKEditor图像对话框形式不可单击

I am using bootstrap modal popup to open ckeditor. It's working but when I to click the image icon in that dialog opens, but not clickable.

  • 写回答

1条回答 默认 最新

  • dongxing2710 2016-03-11 05:33
    关注

    Using this code.

    <script>
        CKEDITOR.replace('help_ldesc');
        //CKEDITOR.replace('help_ldesc1');
    
        $.fn.modal.Constructor.prototype.enforceFocus = function() {
            var $modalElement = this.$element;
            $(document).on('focusin.modal',function(e) {
                    var $parent = $(e.target.parentNode);
                    if ($modalElement[0] !== e.target && !$modalElement.has(e.target).length && $(e.target).parentsUntil('*[role="dialog"]').length === 0) {
                            $modalElement.focus();
                    }
            });
    };
    </script>
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?