While using CRUD,
I have a database field "created"(dataType=>integer
).
When state='list'
the following code converts the integer to date format and display:
$crud->callback_column('created', array($this,'date_display')); //where date_display a function to change date format works
function date_display($value, $row){
return date('d M Y H:i:s',$value);
}
Whereas when state='read'
the above code does not work and neither the function change_field_type
works:
$crud->change_field_type('created', 'datetime');
How to change the integer time to date format in case of state='read'
?