实施时的完整日历问题

2024-02-11

我在实施 FullCalendar 时遇到问题... 我想,我做了“基本用法”主题中所说的所有事情http://arshaw.com/fullcalendar/docs/usage/ http://arshaw.com/fullcalendar/docs/usage/为什么那段代码没有出现在我的 .html 日历上?

<!DOCTYPE html SYSTEM "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>
        Callendar Test
    </title>
    <link rel='stylesheet' type='text/css' href='fullcalendar.css' />

    <script type="text/javascript" src="jquery.js"></script>

    <script type="text/javascript" src='fullcalendar.js'></script>
    <script type="text/javascript">
        $(document).ready(function() {

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

            $('#calendar').fullCalendar({
                // put your options and callbacks here


            })

        });  
    </script>
</head>
<body>
    <div id='calendar'></div>


</body>
</html>

有什么解决办法吗?

P.S.:我下载了 Jquery 文件(版本 1.x)并将其放在与 HTML 页面相同的文件中。

Errors:

Unknown property 'zoom'.  Declaration dropped. fullcalendar.css:107
18:50:38.058 Expected 'none' or URL but found 'alpha('.  Error in parsing value for              'filter'.  Declaration dropped. fullcalendar.css:133
18:50:38.058 Error in parsing value for 'background-image'.  Declaration dropped. fullcalendar.css:213
18:50:38.058 Error in parsing value for 'background-image'.  Declaration dropped. fullcalendar.css:214
18:50:38.058 Error in parsing value for 'background-image'.  Declaration dropped. fullcalendar.css:215
18:50:38.058 Expected 'none' or URL but found 'alpha('.  Error in parsing value for 'filter'.  Declaration dropped. fullcalendar.css:255
18:50:38.058 Expected 'none' or URL but found 'alpha('.  Error in parsing value for 'filter'.  Declaration dropped. fullcalendar.css:414
18:50:38.059 Expected declaration but found '*'.  Skipped to next declaration. fullcalendar.css:532
18:50:38.059 Expected 'none' or URL but found 'alpha('.  Error in parsing value for 'filter'.  Declaration dropped. fullcalendar.css:575
18:50:38.059 Error in parsing value for 'display'.  Declaration dropped. fullcalendar.css:580
18:50:38.092 ReferenceError: moment is not defined fullcalendar.js:12
18:50:38.094 The character encoding of the HTML document was not declared. The document will render with garbled text in some browser configurations if the document contains characters from outside the US-ASCII range. The character encoding of the page must be declared in the document or in the transfer protocol. FullCalendar.html
18:50:38.116 TypeError: $(...).fullCalendar is not a function

这是我的目录:


以防万一其他人通过 Google 发现此线程并遇到同样的问题: 如果您正在使用hostedFullCalendar 的库,您必须包含 moment.js (似乎在托管库上不可用,因此您必须下载它)before您包含 fullcalendar.js 文件。例如:

<script type="text/javascript" src="scripts/moment.js"></script>
<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/fullcalendar/2.0.1/fullcalendar.min.js"></script>

FullCalendar 显然在实例化 Moment 对象之前就有了一些引用。

希望能帮助别人。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

实施时的完整日历问题 的相关文章