A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://webplatform.github.io/docs/javascript/Date/getDate below:

getDate ยท WebPlatform Docs

getDate Summary

Gets the day-of-the-month, using local time.

Syntax
dateObj.getDate()
Return Value

An integer between 1 and 31 that represents the day-of-the-month.

Examples

The following example illustrates the use of the getDate method.

var date = new Date("Jan 01, 2001");
 var str = "Today's date is: ";
    str += (date.getMonth() + 1) + "/";
    str += date.getDate() + "/";
    str += date.getFullYear();
 document.write(str);

 
Remarks

The required dateObj reference is a Date object. To get the day-of-the-month using Universal Coordinated Time (UTC), use the getUTCDate method.

See also Other articles Attributions

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4