# 设置日期和时间

**URL:** <https://www.isharkfly.com/t/topic/8869>\
**Category:** 前端\
**Created:** [December 17, 2012, 1:21am UTC](https://www.isharkfly.com/t/topic/8869 "2012-12-17T01:21:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![honeymoose](https://www.isharkfly.com/user_avatar/www.isharkfly.com/honeymoose/32/20796_2.png) [@honeymoose](https://www.isharkfly.com/u/honeymoose)\
**Post date:** [December 17, 2012, 1:21am UTC](https://www.isharkfly.com/t/topic/8869/1 "2012-12-17T01:21:51Z")

</div>

setYear():设置年

setDate():设置当月号数

setMonth():设置当月份数

setHours():设置小时数

setMintes():设置分钟数

setSeconds():设置秒数

setTime ():设置毫秒数
