Date.getMonth : getMonth : Date JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Date » getMonth »

 

Date.getMonth







The getMonth() method returns the month portion of the Date object expressed as an integer from 0 (January) to 11 (December).












<html>
<head>
<title>Current Month</title>
</head>
<body>
<script language="JavaScript" type="text/javascript">
<!--

var current_date = new Date();

month_value = current_date.getMonth();

document.write("Current Month is " + month_value);

//-->
</script>
</body>
</html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Date
» getMonth