image upload error

Permalink
Am getting a consistent error when uploading images.
The file dosent upload correctly and in the process i do not see the option at the end of file upload for sets etc.
See the screen grab and you will see although a file is there its size displays as 'zero' even though your can view the file and it looks ok, there are no previews and it does not show when trying to place in an image block.
This is on a clean install of 7.5.2.

1 Attachment

deanhawthornthwaite
 
barkingtuna replied on at Permalink Reply
barkingtuna
There is no screenshot, but I have been experiencing the exact same thing. I get a 500 Error when I try and replace an existing file and when I do upload, it shows NO thumbnail and shows it as a 0.0KB file size.
barkingtuna replied on at Permalink Reply
barkingtuna
There is no screenshot, but I have been experiencing the exact same thing. I get a 500 Error when I try and replace an existing file and when I do upload, it shows NO thumbnail and shows it as a 0.0KB file size.
MrKDilkington replied on at Permalink Reply
MrKDilkington
@deanhawthornthwaite
@barkingtuna

Have you checked the concrete5 logs?
https://www.concrete5.org/documentation/using-concrete5-7/dashboard/...

Have you checked the Apache and PHP error logs for your server?
deanhawthornthwaite replied on at Permalink Reply 1 Attachment
deanhawthornthwaite
Checked the c5 logs and it has a number of identical entries by date as below (see image) but no other info. Checked the hosting error logs and it was empty.

Sep 30, 2015, 11:48:14 AM Application admin Image Inspector
Sep 30, 2015, 11:48:12 AM Application admin Image Inspector
Sep 30, 2015, 11:48:10 AM Application admin Image Inspector
Sep 30, 2015, 11:48:08 AM Application admin Image Inspector
Sep 30, 2015, 11:48:06 AM Application admin Image Inspector
deanhawthornthwaite replied on at Permalink Reply 2 Attachments
deanhawthornthwaite
Just tried uploading a batch of images. First batch worked fine (file sizes under 170kb) second batch produced error... 'Maximum execution time of 60 seconds exceeded'. (see image). Second batch file sizes were bigger at a max of 1.7mb but interstingly, the files listed in the error were no bigger than 600kb.
Could it be something to do with files sizes allowed by CMS or broadband connection consitency?
My server PHP config shows file settings. (see image).
deanhawthornthwaite replied on at Permalink Reply 1 Attachment
deanhawthornthwaite
The plot thickens.. just refreshed the files page and it look like none of the second batch if images uploaded correctly (see image).
barkingtuna replied on at Permalink Reply
barkingtuna
Had a similar issue and have another thread open. A workaround was proposed that works for me. See if it does in this case as well.

https://www.concrete5.org/community/forums/5-7-discussion/5.7.critic...
barkingtuna replied on at Permalink Reply
barkingtuna
Did it work?
deanhawthornthwaite replied on at Permalink Reply
deanhawthornthwaite
Sorry been out of the loop.

I had a look at the image.php file and the code is the same as on your link so not sure if that code is the amended code or not? I'm not a programmer so anything other than finding and replacing is beyond me.
MrKDilkington replied on at Permalink Reply
MrKDilkington
@deanhawthornthwaite
@barkingtuna

Have you checked the bug tracker to see if others are experiencing this issue? If no one has reported this issue, I recommend reporting it and including the steps required to repeat the error.

concrete5 bug tracker
https://www.concrete5.org/developers/bugs...
barkingtuna replied on at Permalink Reply
barkingtuna
I posted a bug report with steps, error logs, and fixes since there was nothing like this in there.

https://www.concrete5.org/developers/bugs/5-7-5-2/image-uploads-timi...
barkingtuna replied on at Permalink Reply
barkingtuna
Hi... I'm a lot like you. I can copy and paste with regards to the complicated issues. However, you may have missed that a chunk of it was commented out per the suggestion in the post I forwarded to you. The original code is such:

<?php
namespace Concrete\Core\Support\Facade;
class Image extends Facade
{
    public static function getFacadeAccessor()
    {
        if (class_exists('Imagick')) {
            try {
                $imagick = new \Imagick();
                $v = $imagick->getVersion();
                list($version, $year, $month, $day, $q, $website) = sscanf(
                    $v['versionString'],
                    'ImageMagick %s %04d-%02d-%02d %s %s');
                if (version_compare($version, '6.2.9') >= 0) {
                    return 'image/imagick';


and the modified code, which you can copy and paste presumably that comments out the "Imagick" section is:
<?php
namespace Concrete\Core\Support\Facade;
class Image extends Facade
{
    public static function getFacadeAccessor()
    {
        /**if (class_exists('Imagick')) {
            try {
                $imagick = new \Imagick();
                $v = $imagick->getVersion();
                list($version, $year, $month, $day, $q, $website) = sscanf(
                    $v['versionString'],
                    'ImageMagick %s %04d-%02d-%02d %s %s');
                if (version_compare($version, '6.2.9') >= 0) {
                    return 'image/imagick';


Look at lines 10 & 23 for the /** and **/. That was the only modification. I cleared cache and tried the uploads and they all worked immediately after.
deanhawthornthwaite replied on at Permalink Reply
deanhawthornthwaite
Hey barkingtuna, thanks so much for what you have done!
Have replace the code now and uploads are perfect!!!

Really apprecaite all the help from everyone.
MrKDilkington replied on at Permalink Reply
MrKDilkington
@deanhawthornthwaite

If you are experiencing the same issue as barkingtuna, please add your input and vote for the issue that was created. This helps the core team identify issues.

https://www.concrete5.org/developers/bugs/5-7-5-2/image-uploads-timi...