$(document).ready(function (){ for(var t = 1970; t $("#yearsel").append(""); } for(var y = 1; y $("#monthsel").append(""); } var year = new Date().getFullYear(); var month = new Date().getMonth()+1; var day = new Date().getDate(); var w = getTime(year,month,1).getDay()-1; var num = day + w -1; $("#yearsel").change(function(){ year = $("#yearsel option:selected").text(); month = $("#monthsel option:selected").text(); view(year,month); }); $("#monthsel").change(function(){ year = $("#yearsel option:selected").text(); month = $("#monthsel option:selected").text(); view(year,month); }); var oDate = ['星期一','星期二','星期三','星期四','星期五','星期六','星期日',]; for(var i = 0;i $("#title").append("