Scripts: Javascript :: Date and Time Functions :: Library Article #14
Developer's Section
![]() By: Erobo Team Member
|
|||
![]()
Here is a simple script that gives you the number of days of a current month.
The function getNumDaysMonth takes as input the year and the month number and
returns the current number of days for that particular month. The script itself
works by calculating the type of year (leap-year or non-leap year) given a month using the remainder operation.
it selects the number of days from several predefined arrays.
|
|||
|
|||
![]() |
|
![]() the form below: |