在AWS上获取“ jQuery.Deferred异常”,但不在本地

问题描述

当我在本地加载此文件时,一切正常。但是当部署在AWS EC2上时,出现此错误

jQuery.Deferred exception: $(...).timepicker is not a function TypeError: $(...).timepicker is not a function
    at HTMLDocument.<anonymous> (http://ec2-URL:3000/page.html:42:31)
    at j (https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0/jquery.min.js:2:29588)
    at k (https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0/jquery.min.js:2:29902) undefined

我的代码

<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.0.0/jquery.min.js"></script>
<script src="https://code.jquery.com/ui/1.10.4/jquery-ui.js"></script>

<link href="//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css" rel="stylesheet">

<script src="//cdnjs.cloudflare.com/ajax/libs/timepicker/1.3.5/jquery.timepicker.min.js"></script>
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/timepicker/1.3.5/jquery.timepicker.min.css">

<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-modal/0.9.1/jquery.modal.min.js"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/jquery-modal/0.9.1/jquery.modal.min.css" />
    
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">

<script>
    $(document).ready(function(){
        $('input.timepicker').timepicker({
            timeFormat: 'HH:mm',interval: 60,minTime: '00',maxTime: '23:30',defaultTime: '07',startTime: '00:00',dynamic: false,dropdown: true,scrollbar: true});
    });
    var shiftRows = 0;
</script>
</head>

我尝试对脚本加载的顺序进行不同的排序,但是无法正常工作。我在做什么错了?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)