I am using ZF 1.11, PHP 5.3, Windows and the most recent version of zfdatagrid.
I use
$grid->updateColumn('birthday', array('format'=> array('date',array('date_format' => 'dd-MM-yyyy'))));
to display an attribute "birthday" as dd-MM-yyyy. When I click on the Edit button (CRUD enabled), the value of this attribute is being displayed as 'yyyy-MM-dd'. When the user clicks the save button, he gets an error message (Please, enter date as dd-MM-yyyy).
How can I tell the $form to display the value as dd-MM-yyyy instead of yyyy-MM-dd?
thanks, but that doesn't solve the problem. Actually, what I did now is to add an event listener for the crud.form_built event. The method called in this event simply creates a new Zend_Validate_Date object and assigns this validator to the corresponding zfdatagrid element.
This is a hack indeed, but it works. Actually, zfdatagrid doesn't really work with PostgreSQL and the manual is incorrent in many places.