Need a quality coder? The author of this blog is now freelancing:
Freelance PHP/CakePHP Web Developer Bristol / Southwest UK
If you’re trying to use the CakePHP Media plugin with 1.3 (I’m running RC3) and you get this error when deleting an attachment:
1 | Call to undefined method Folder::ls() in /path_to_app/app/plugins/media/models/behaviors/media.php on line 277 |
ls() has been deprecated in favour of read(), change line 277 of /path_to_app/app/plugins/media/models/behaviors/media.php to:
1 | list($versions, ) = $Folder->read(); |
All should work fine thereafter ;]
2 Responses to Call to undefined method Folder::ls() on line 277 – CakePHP 1.3 with Media plugin
Yura
May 6th, 2010 at 5:05 pm
Yes, and there was another thing I had to fix before I got Media plugin work in CakePHP 1.3.
Configure::read(’vendorPaths’) doesn’t work in 1.3 anymore and should be replaced with App::path(’vendors’)
in app/plugins/media/vendors/mime_type.php at the end of the file in function __db($type)
It was a hair puller for me, so maybe it’ll help someone.
phpdeveloper
June 25th, 2010 at 11:34 am
this helped me a lot..thanks….