JavaScript Reference/Javascript Methods/getMonth
Версия от 18:30, 25 мая 2010; (обсуждение)
"getMonth()" Example
<html>
<body>
<button onclick="var myDate = new Date(); alert(myDate.getMonth());">
get month</button>
</body>
</html>
"getMonth()" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |Date |
+----------------+--------------------------------------------------------------+
"getMonth()" Syntax, Parameters and Note
Note:
Returns the month.
Return value:
0 to 11,
with 0 representing January and 11 representing December.
Syntax:
dateName.getMonth()