900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > 精通 CSS+DIV 网页样式与布局 165

精通 CSS+DIV 网页样式与布局 165

时间:2022-12-26 11:13:24

相关推荐

精通 CSS+DIV 网页样式与布局 165

calElement(sYear,sMonth,sDay,week,lYear,lMonth,lDay,isLeap,cYear,cMonth,cDay)

{

this.isToday = false;

//国历

this.sYear = sYear; //西元年 4 位数字

this.sMonth = sMonth; //西元月数字

this.sDay = sDay; //西元日数字

this.week = week; //星期, 1 个中文

//农历

this.lYear = lYear; //西元年 4 位数字

this.lMonth = lMonth; //农历月数字

this.lDay = lDay; //农历日数字

this.isLeap = isLeap; //是否为农历闰月?

//八字

this.cYear = cYear; //年柱, 2 个中文

this.cMonth = cMonth; //月柱, 2 个中文

this.cDay = cDay; //日柱, 2 个中文

this.color = ”;

this.lunarFestival = ”; //农历节日

this.solarFestival1 = ”; //国历节日 1

this.solarFestival2 = ”; //国历节日 2

this.solarFestival3 = ”; //国历节日 3

this.solarTerms = ”; //节气

}

//===== 某年的第 n 个节气为几日(从 0 小寒起算)

function sTerm(y,n) {

var offDate = new Date( ( 31556925974.7*(y-1900) + sTermInfo[n]*60000 ) +

Date.UTC(1900,0,6,2,5) );

return(offDate.getUTCDate());

}

//============================== 传回月历物件 (y 年,m+1 月)

/*

功能说明: 传回整个月的日期资料物件

使用方式: OBJ = new calendar(年,零起算月);

OBJ.length 传回当月最大日

OBJ.firstWeek 传回当月一日星期

由 OBJ[日期].属性名称 即可取得各项值

OBJ[日期].isToday 传回是否为今日 true 或 false

其他 OBJ[日期] 属性参见 calElement() 中的注解

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。