fixed date format for compatiblity with mysql