在FullCalendar错误中将事件提取为json:$ ajax附近的未定义功能

时间:2019-03-16 23:40:08

标签: javascript ajax fullcalendar

我想通过som习俗事件充实FullCalendar,每次尝试使用Ajax或Json events时都会出现此错误

Uncaught TypeError: undefined is not a function near (...$.ajax...)

这是我的FullCalendar的javascript代码:

$(function() {

    // page is now ready, initialize the calendar..

    $('#calendar').fullCalendar({
        themeSystem: 'bootstrap4',
        header:{
            left: 'month,agendaWeek,agendaDay',
            center: 'title',
            right: 'prev,today,next'
        },
        defaultView: 'month',
        weekNumbers: true, 
        weekNumberTitle: "Week",
        slotLabelFormat: 'H:mm',
        nowIndicator: true,
        navLinks: true,

        events: getEvents
    });
});

1 个答案:

答案 0 :(得分:1)

最后,我发现我正在加载不包含ajax函数的Jquery的精简版(我想像是不好的剪切/粘贴操作)。

我希望它将对某人有所帮助