It was easy to find a way to get last day of because of php. Then you can easily check it by if conditions as mentioned in the code below: Thanks for contributing an answer to Stack Overflow! Conditions for a force to be conservative. High income, no home, don't necessarily want one. Can someone explain why this German language joke is funny? How do you get a timestamp in JavaScript? Why is unappetizing food brought along to space? We used the “n” format character because it will return a number between 1-12 without any leading zeros. In what way would invoking martial law help Trump overturn the election? or just include it inside the constructor in this form new DateTime("now", $myTimezone); Very easy with the dateTime() object, too. A very common feature of forms is the dropdown