简体   繁体   English

cakephp和imagick-无法上传原始文件

[英]cakephp and imagick - raw files won't upload

When I upload a JPEG everything works just fine. 当我上传JPEG时,一切正常。 However, when upload a RAW it does work. 但是,上载RAW时可以正常工作。 I have the php.ini upload limits set to 25M. 我的php.ini上传限制设置为25M。 I was able to upload a 7MB JPEG file but not a 7MB RAW file. 我能够上传7MB JPEG文件,但不能上传7MB RAW文件。 Below is the error I am recieving: 以下是我收到的错误:

[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: PHP Fatal error:  Uncaught exception 'ImagickException' with message 'Can not process empty wand' in /home/photobound/public_html/plugins/photo_bank/models/photo_bank_image.php:264, referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: Stack trace:, referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #0 /home/photobound/public_html/plugins/photo_bank/models/photo_bank_image.php(264): Imagick->getimagewidth(), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #1 /home/photobound/public_html/plugins/photo_bank/models/photo_bank_image.php(124): PhotoBankImage->computeImageFieldsForSave(), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #2 /usr/share/php/cake/cakephp/cake/libs/model/model.php(1282): PhotoBankImage->beforeSave(Array), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #3 /home/photobound/public_html/plugins/photo_bank/controllers/photo_bank_images_controller.php(131): Model->save(Array), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #4 [internal function]: PhotoBankImagesController->upload('-1'), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #5 /usr/share/php/cake/cakephp/cake/dispatcher.php(204): call_user_func_array(Array, Array), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #6 /usr/share/php/cake/cakephp/cake/dispatcher.php(171): Dispatcher->_invoke(Object(PhotoBankImagesController), Array), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #7 /home/photobound/public_html/webroot/index.php(84): Dispatcher->dispatch(), referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr: #8 {main}, referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf
[Wed Aug 17 17:23:55 2011] [warn] [client 192.168.1.6] mod_fcgid: stderr:   thrown in /home/photobound/public_html/plugins/photo_bank/models/photo_bank_image.php on line 264, referer: http://photobound.local/photo_bank/js/plupload/plupload.flash.swf

Here is the code on line 264: 这是第264行的代码:

$this->data['PhotoBankImage']['width'] = $this->image->getImageWidth();

Here are my php.ini settings that I thought were relevent: 这是我认为与事件无关的php.ini设置:

post_max_size = 25M
post_max_size = 25M
memory_limit = 512M
max_execution_time = 120
max_input_time = 120

I'd appreciate any help, let me know if you need anything else from me in order understand the problem. 我将不胜感激,如果您需要我提供其他帮助以了解问题,请告诉我。

RAW files are not standard images. RAW文件不是标准图像。 Standard graphics libraries are not going to be able to work with them. 标准图形库将无法使用它们。 The format varies depending on camera make/model, etc. 格式因相机品牌/型号等而异。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM