I have this function which gets the date and time from the database table.this is the format in the table
2006-02-13 10:22:34. now i want to print the date, i get this error Notice: A non well formed numeric value encountered.......when i did a print_r(). i got this Array (  => 2006  => 02  => 13 10:22:34 ).so i guess  which contains the day and time is causing this error.how can i solve this problem.please help.
$arr = explode("-", $val);
return date("d. F Y.", mktime (0,0,0, $arr, $arr, $arr));