Common methods of date objects

The definition of date object:
var datce = new Date();

toString() Date to string [ Tusi blown]
toLocaleString() Date to local format string [
Tuloukou silk blown] getFullYear() Get year [Getty or not]
getMonth() Get month [ Getty] Busy]
getDate() Get the number of days [Getty dei special]
getDay() Get the number of weeks [Getty dei]
getHours() Get the number of hours
[Getty, my son] getMinutes() Get the number of minutes [Getty Minutes ]
GetSeconds() Get the number of seconds, [Gate Saiken word]
getMilliseconds() Get the number of milliseconds [Gate Milin Saiken word]
getTime() Get the number of milliseconds [Gate Taimu ]
setFullYear(Year) Set the year [Site No Yeah]
setMonth(Month) Set month [Site busy to death]
setDate(Days) Set days [Site dei special]
setHours(Hours) Set hours [Site ah
myer silk] setMinutes(Minutes) Set Minutes [Site Min Times]
setSeconds (seconds) set the seconds [Site Saiken word]
setMilliseconds (milliseconds) set the number of milliseconds [Site Mi Lin Saiken word]

Guess you like

Origin blog.csdn.net/jq1223/article/details/112727289