javascript two date is in one month code example Example: get month in two digit in javascript date ("0" + (this.getMonth() + 1)).slice(-2)