问题
I am using this code
<script type='text/javascript'>
$(document).ready(function() {
$('#calendar').fullCalendar({
firstDay: 2,
eventSources: [
{
url: 'data.php',
type: 'POST'
}
]
})
});
</script>
but the calendar still starts on Sunday
According to their docs, I am using it right
What is the problem?
回答1:
It's probably an issue with your libraries. Be sure to use the latest version of fullcalendar (2.1.1) and include momentjs.
<link href="//cdnjs.cloudflare.com/ajax/libs/fullcalendar/2.1.1/fullcalendar.css" rel="stylesheet">
<script src="//cdnjs.cloudflare.com/ajax/libs/moment.js/2.8.3/moment.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/fullcalendar/2.1.1/fullcalendar.min.js"></script>
Check this working jsfiddle
来源:https://stackoverflow.com/questions/26526280/fullcalendar-firstday-doesnt-work