JS Program Development-3

Source: Internet
Author: User

Get Date and time

GetDate () Get Day 1-31

GetDay () Get Week 0-6

GetMonth () Get month 0-11

getFullYear () Get the full year (browser supported)

GetHours () Get hours 0-23

Getminutes () Get minutes 0-59

Getseconds () Get seconds 0-59

Getmilliseconds () Gets the current millisecond

GetTime () returns the cumulative number of milliseconds (from 1970/1/1 midnight)

SetInterval () This method invokes the function or evaluates the expression by the specified period (in milliseconds), and it calls the function repeatedly until Clearinterval () is called or the window is closed, and the ID value returned by SetInterval () is used as the Parameters of the Clearinterval () method

SetTimeout () This method is used to call a function or evaluate an expression after a specified number of milliseconds, and it executes code only once. If you want to call more than once, use SetInterval () or let code itself call SetTimeout () again.

JS Program Development-3

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.