hey,
i have a script which i have the user choose a date via dropdowns and end up with 4 fields in my DB
with
Day
date
month
year
but down i im at the point where i want to have the events which i retrieve from the DB to be sorted by date, from the newest to the oldest.
and while i like the format it displays of
Sunday 1/1/2007
its all done like:
PHP Code:
$content .= $row['day']; $content .= ' '; $content .= $row['date']; $content .= '/'; $content .= $row['month']; $content .= '/'; $content .= $row['year'];
so how would i go about having the script order it by date??
also how could i validate that the input is a valid date?
so if they input
Sunday 25 / 02 / 2007
and it happens that the 25th of feb 2007 is actually a monday
or they enter something like 30/02/2007 which obviously isnt right...
Thanks
TAlkupation for people who help.
Dan
__________________
Personal UK Webhosting Get 25% of ANY shared package for life ~ Promo: webmaster-talk (only for members!)
|