I have trouble saving my date field into database using CakePHP.
Table column name
[User].[dob]
View
<?php echo $this->Form->input('dob', array('type'=> 'date', 'label' => FALSE, 'dateFormat' => 'DMY', 'minYear' => date('Y') - 111, 'maxYear' => date('Y'))); ?>
I get the following error when I submit the form –
2011-12-29 00:33:57 Debug: Notice (8): Array to string conversion in [C:\xampp\htdocs\dearmemoir\cake\libs\router.php, line 1573]
This field is part of the Auth User Model. Any ideas what might be going wrong?
This line of code did the magic for me –
I am able to save data now!