模态不是函数内部的函数

modal is not a function inside a function

本文关键字:函数 内部 模态      更新时间:2023-09-26

当我回答true时,它显示了一个错误:

模态不是的函数

false时,它显示HTML精细。我不明白为什么html()有效而modal()无效。

$('#conxModal').modal('toggle'); // Work here    
function postProcessing(data) {
        $.each(data, function(key, val) {
            if (val == true) {
                $('#conxModal').modal('toggle');
            }
            if (val == false)   {
                $("span#erreurcnx").html('bad');
            }
        });
    }

我添加:

jQuery.noConflict();

它是修复。