$date = date('Y-m-d h:i');
I have been using this function for recording date in my tables. Previosuly i use to create date using wrong function like mktime.
$date = date('Y-m-d h:i');
I have been using this function for recording date in my tables. Previosuly i use to create date using wrong function like mktime.
Easy one:
$today = date('l'); // returns Sunday
When you want it to do like your image, you should get your date from the dropdown. Then do the following:
$date = '2017-7-27 10:51:10'; // example date
var_dump(date('l', strtotime($date))); // returns Sunday
Goodluck!