Jquery datepicker does not work inside lightbox

后端 未结 4 1934
失恋的感觉
失恋的感觉 2020-12-22 10:10

After some problems solved, I got a tricky stuff. I am using an overlay plugin for JQuery called prettyPhoto.

Just wanna make an overlay with a form. The form is hid

4条回答
  •  独厮守ぢ
    2020-12-22 10:47

    with lightbox doest not work. This is because the lightbox always enforce focus on itself.

    var enforceModalFocusFn = $.fn.modal.Constructor.prototype.enforceFocus;
    
    $.fn.modal.Constructor.prototype.enforceFocus = function() {};
    
    $confModal.on('hidden', function() {
        $.fn.modal.Constructor.prototype.enforceFocus = enforceModalFocusFn;
    });
    

提交回复
热议问题