cakephp-2.8

Cakephp migration from 2.7 to 2.8 in cpanel

馋奶兔 提交于 2020-01-17 01:37:07
问题 My website is developed in cakephp 2.7 which uses php.4.4 many years ago.All working fine at that time. But right now it's not working in capnel. I have checked the issue and error logs. PDO class is not working and meanwhile database query execution is not working. So i have upgraded my php version to PHP 7.0. Another issues are coming like problem in error handler of cakephp. I searched for this issue and i concluded that cakephp 2.7 is not compatible with PHP 7.0. So i have to do migration

Cakephp 2.8.4 ignoring hasMany

╄→гoц情女王★ 提交于 2019-12-25 07:38:18
问题 This is a very odd issue that I have not been able to figure out for a very long time. I have a model Upload , with several hasMany all being ignored by UploadModel . For example. Upload hasMany Face . On comments table I have a field called foreign_key that hosts the Upload.id. So the relationship in UploadModel looks like this: $hasMany = ['Face' => ['foreignKey' => 'Face.upload_id']]; When performing a find in Upload with contain Face + conditions [Face.celebrity_id = 4018] I get the