I have a field in a MySQL database with a date in it.
It is a date field and the data looks like this : 2006-04-30 ex.
If I then gets it from the database it wil off cause write 2006-04-30 on the screen.
But now I need to know what day it is, so if the date is 2006-04-30 it should write Sun or Sunday.
I can see that it should be something like $day = date('D', $date); where date is the direct date (2006-04-30) from the database.
But it won't work.
if I write
$date='2006-04-30';
echo date('D', $date);
it writes Thu
I don't get it
Could someone please help