Jump to content

Form Date Menu


Daguse

Recommended Posts

Javascript 'date pickers' are a dime-a-dozen as a quick Google will show you.  Assuming that you don't want to use javascript, then your choices are restricted to a 3-dropdown set - days 1-31, months 1-23, years whenever to whenever.  You could handcode it all using plain html or use php to loop through and create your dropdowns.  It's up to you how you to decide.
Link to comment
https://forums.phpfreaks.com/topic/23963-form-date-menu/#findComment-108902
Share on other sites

It's a relatively simple process in PHP to create a dropdown of, say, all dates in the next month or the next 20 Mondays, or next weeks dates.

Have a look at these functions

http://www.php.net/mktime
http://www.php.net/strtotime
http://www.php.net/date

Link to comment
https://forums.phpfreaks.com/topic/23963-form-date-menu/#findComment-108912
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.