Can someone give me a quick and dirty way to split a datetime (28-1-2011 14:32:55) into just the date (28-1-2011) and the time ( 14:32 ) or even better (2:32 PM) using PHP.
If you looking for a really quick and dirty solution.
$datetime = "28-1-2011 14:32:55"; $date_arr= explode(" ", $datetime); $date= $date_arr[0]; $time= $date_arr[1];