0
Good afternoon everyone, I’m having a question on a course project. I have a form where I look for scheduled patients on a certain day of the month.
When I perform the appointment to present the scheduled patients, I must also present what would be the day of the week, that day of the month used in select. The date format is in the "day/month/year".
How could I do that?
To display the day of the week you can use D when formatting the date.
echo date("D", strtotime("20/12/2017"));
http://br.php.net/manual/en/function.date.php– Valdeir Psr
The example you sent me worked in part, I need it to be dynamic. I receive the date that will be used in the query in the following variable "$p_data" based on that date I need to display the day of the week.
– João Victor
You just pass the variable to the function
strtotime($variable)
– Valdeir Psr
Thank you very much, the solution worked!
– João Victor