. Advertisement .
..3..
. Advertisement .
..4..
I’m learning Javascript. Can you give me some examples to get the number of days in a month in javascript? Thank you.
Here is a case study for you var dt = new Date();
var month = dt.getMonth();
var year = dt.getFullYear();
daysInMonth = new Date(year, month, 0).getDate();
1 Answer