Post by crashby » Mon Jun 20, 2011 7:14 pm

After a bit of debugging the PHP, it turns out that there were a bunch of corrupted JPEGs that were throwing some errors. Unfortunately these errors were being output along with the JSON object that the Filemanager template processes, causing it to implode and do nothing, without any error messages.

The solution was to go to Settings->Server and change "Display Errors" to No, and save.

This allowed the filemanager to work correctly again.

Hopefully this will help others who are experiencing this problem.

Newbie

Posts

Joined
Mon Jun 20, 2011 6:37 pm

Post by crashby » Mon Jun 20, 2011 9:55 pm

Scrub that. Now i've solved that issue, a new one occurs. New image uploads are failing, despite Filemanager reporting "Success!". The file is in the Data folder, but there's no sign of the resized versions in the Cache so they don't show on the filemanager.

this is driving me nuts.

Newbie

Posts

Joined
Mon Jun 20, 2011 6:37 pm

Post by Daniel » Tue Jun 21, 2011 1:43 am

chmod 777

also check what permissions your host allows when it creates new directories.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by crashby » Tue Jun 21, 2011 4:29 pm

I'd already changed to 777.

New directories are working via the filemanager, but are created with permissions of 755.

Files uploaded are being put in the correct place in data.

The created directories are being created in the cache.

It is just the resized images that are failing to be created in the cache.

This has been working for a couple of months without problems.

I'm going to debug the code to determine exactly where it is failing.

Newbie

Posts

Joined
Mon Jun 20, 2011 6:37 pm

Post by crashby » Tue Jun 21, 2011 4:54 pm

OK, USER ERROR!

I had deleted a line of code debugging the other issue :-[

it's all working now.

Newbie

Posts

Joined
Mon Jun 20, 2011 6:37 pm

Post by daledude » Fri Jul 01, 2011 3:50 am

Another suggestion for a possible fix:

I had added https://domain.com/folder/ as the HTTPS_SERVER and HTTPS_IMAGE in the admin/config.php, and even though there IS technically an SSL certificate installed for the account, for some idiotic reason it's not working (hurray!). After trying tons of permissions changes, deleting folders and re-creating the image/image/data,etc. folders, yadda yadda, unsure why my images weren't showing up, I took off the 'S' on http*s*:// for HTTPS_SERVER and HTTPS_IMAGE, went back to the Image Manager, and there all my images were. :laugh: I will never again turn on SSL while I'm working...

In all of the posts I've read on this, nobody has ever mentioned checking this setting in config.php that I found... so this may help someone

New member

Posts

Joined
Thu Dec 17, 2009 1:30 am

Post by Daniel » Fri Jul 01, 2011 11:29 pm

i have been to 100's of people sites who claim the they have problems with the images and on everyone i have found its down to incorrect settings done by the host, incorrect permissions, config.php, php safe mode, etc..

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by shonedenver » Thu Aug 18, 2011 11:38 am

im not sure how this will help any one,.. but I have been having the same issue with v1.5.0.5 image manager,

I found out that if the file name is too long then the image will not show in the folder, not only will it not show that particular image, but it will not show any images in that folder.

I tested this by shortening the name to about 15 to 18 characters and the images show up with out an issue.

But if there is at-least one image with a long name or no extension then the whole folder will be empty in the image manager.

Again not sure how this will help but this is how I got around this issue.

Newbie

Posts

Joined
Fri Jul 15, 2011 3:58 pm

Post by Daniel » Thu Aug 18, 2011 1:21 pm

shonedenver wrote:im not sure how this will help any one,.. but I have been having the same issue with v1.5.0.5 image manager,

I found out that if the file name is too long then the image will not show in the folder, not only will it not show that particular image, but it will not show any images in that folder.

I tested this by shortening the name to about 15 to 18 characters and the images show up with out an issue.

But if there is at-least one image with a long name or no extension then the whole folder will be empty in the image manager.

Again not sure how this will help but this is how I got around this issue.

works fine for me if i set the filename to 40 characters. i think this maybe something to do with how your server is setup. again not opencarts fault.

if you have a file with no extension then you must have put it there! because the system will not upload images with no file extension.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by shonedenver » Fri Aug 19, 2011 8:52 pm

if the file is 44 and above i see the issue..... any thing less than 43 is fine

Newbie

Posts

Joined
Fri Jul 15, 2011 3:58 pm

Post by Daniel » Sat Aug 20, 2011 4:35 pm

someone also posted you can;t use & in the filename. i think some servers have some settings that restrict what can be used in filenames

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by madimar » Mon Aug 29, 2011 10:57 pm

mberlant wrote:You very likely have a corrupt image file in your images directory. This is a known issue that has been discussed in about half a dozen threads here.

Use your favorite FTP tool to look at your images directory. Delete the image file with the most recent timestamp. You will likely find that your other images reappear.

My experience is that the image uploader tends to corrupt .png files, especially tiny ones like favicon.png.

Good luck.
I'm experiencing similar issues with image manager after an update from OC 1.3.2 to 1.4.9.6.
In 1.3.2 with the same set of images everything worked perfectly. Now I can't see any image in image manager (in 1.4.9.6). Permissions seem ok. Image folders/files set to 777.
Now, I understand maybe there is a corrupted image file... but I have more than 5000 image files so it is not so easy to check things.
Anyway, considering it was working fine with 1.3.2, I would say that, even if maybe not a real bug of image manager, it is an annoying "eccess of sensitivity" of the new image manager. How it is possible that a single corrupted image file breaks everything? No way to improve things?

Thanks in advance,
regards,

M

-----------------------------------------------------------------------
My last mods: Partita IVA e CF | Pro EU VAT Number | Sales Agents | Pricelist Pro
-----------------------------------------------------------------------


User avatar
Active Member

Posts

Joined
Thu Sep 24, 2009 6:27 pm


Post by madimar » Mon Aug 29, 2011 11:13 pm

crashby wrote:After a bit of debugging the PHP, it turns out that there were a bunch of corrupted JPEGs that were throwing some errors. Unfortunately these errors were being output along with the JSON object that the Filemanager template processes, causing it to implode and do nothing, without any error messages.

The solution was to go to Settings->Server and change "Display Errors" to No, and save.

This allowed the filemanager to work correctly again.

Hopefully this will help others who are experiencing this problem.
"Display Errors" set to "No" workaround worked for me too. I still remain in the opinion this can be considered as a "weakness" of the image manager, even if not a real bug.

-----------------------------------------------------------------------
My last mods: Partita IVA e CF | Pro EU VAT Number | Sales Agents | Pricelist Pro
-----------------------------------------------------------------------


User avatar
Active Member

Posts

Joined
Thu Sep 24, 2009 6:27 pm


Post by Daniel » Tue Aug 30, 2011 1:27 am

i will lokk into it.

the jpgs seem to become corrupt if the execution time to resize the jps takes to long.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by madimar » Tue Aug 30, 2011 2:07 am

Thank you really Daniel for your time

Sent from my Desire HD using Tapatalk

-----------------------------------------------------------------------
My last mods: Partita IVA e CF | Pro EU VAT Number | Sales Agents | Pricelist Pro
-----------------------------------------------------------------------


User avatar
Active Member

Posts

Joined
Thu Sep 24, 2009 6:27 pm


Post by adrian_mirea » Wed Sep 28, 2011 9:52 pm

I had a similar problem recently and that's how I found this topic.

Just writing to let you know how it was fixed for me in case anyone else does the same mistake.

Daniel is right, usually there is a misconfiguration of some sort that is the source for this type of problems, even if at some point I was almost sure this is an issue with the image manager.

In my case it wasn't a permissions issue, but an issue with the admin config.php. I recently moved my site from a domain to another one. I replaced most of the references to the old website, both in the config files and in the db, however in config.php I made a little error. Instead of writing http://www.mywebsite.com at the

Code: Select all

define('HTTPS_IMAGE', 'http://www.mywebsite.com/image/');
I wrote:

Code: Select all

define('HTTPS_IMAGE', 'http://mywebsite.com/image/');
This was the reason image manager was not displaying any images for me; after putting the "www" back in there it worked. Just writing in case someone else makes the same/a similar mistake in their config and finds this topic. :)

Newbie

Posts

Joined
Wed Sep 28, 2011 9:27 pm

Post by cuma_elp » Sat Nov 05, 2011 1:46 am

i got another error message about this matter lately. why? cos i never found this problem on the same site before. it just happened recently.

this error message produced when i tried to lookout the problem why the image doesn't appear on my image manager. not all of the images,(how can i say this) it only viewing the cached images. new image that i've just uploaded, it doesn't appear at all. but it all give success message when i upload it. i've checked it through ftp client and they're exist.

Code: Select all

<br />
<b>Fatal error</b>:  Allowed memory size of 67108864 bytes exhausted (tried to allocate 18432 bytes) in <b>/home/mydomain/public_html/system/library/image.php</b> on line <b>34</b><br />
oh, almost forgot, i got this error message when check it with firebug (console mode) to viewing the JSON result.
i think the problem are : it failed to create a copy of the new image from /public_html/image/data/ to /public_html/image/cache/data/ and it related to memory issue...
does anyone knows how could this problem exist and how to solve it?

i'm sorry for my english :)

Newbie

Posts

Joined
Sat Nov 05, 2011 1:26 am

Post by karlopencart » Sat Nov 26, 2011 3:18 am

Postby Daniel » Mon Jun 20, 2011 5:43 pm
chmod 777
I have to agree with Daniel.

First time I got this problem it was down to permissions and chmod 777 cured the problem.

Second time it was down to a corrupt .png - delete and image mgr is back working

Third time it was down to a corrupt .jpg with a filesize of 0 (zero) on this occasion it was caused by a bad zip file of over 5000 images. It was just one image but it cost 2 hours :crazy:

1. chmod 777 your image data directories
2. clear your image data cache
3. check file size for 0 (zero) size images and delete

So I tested a few 0 (zero) size files .png .jpg .gif and yes it busted the image manager everytime.

Just remember when you refresh and go to image manager give it a minute to refresh the cache.

Hope this helps, I'm no OC Guru but most of the answers are in the forum so as you read you learn well I have learn't loads.

Karl

-----------------------------
1 Shop - OC 1.5.1.3
5 Shops - OC 1.4.9.3
2 Shops - OC 1.4.7

User avatar
New member

Posts

Joined
Tue Oct 05, 2010 11:19 pm

Post by bigboss » Sat Nov 26, 2011 9:23 am

======================================
I also have this problem.
======================================
I have tried to use IE and firefox, both of them can't show the pictures.
I have rebooted my computer, but the same problem.
This problem occured 1 time (1 day) for my server. On the other days, there is no problem. I don't know why.
----------------------------
I have just checked the previous post, the problem may be caused by a damaged pictures.
----------------------------
Anyway, I think that this image manger is not good for manage a large/huge numbers of pictures (i.e more than 1000 photos). I also hope that opencart can allow to upload a custom product listing thumbnail.

New member

Posts

Joined
Sun Jul 25, 2010 10:35 am

Post by Daniel » Sat Nov 26, 2011 2:21 pm

how about you split the images into different directories!

its about using your brain. there are limitations on the image manager because of the maximum execution time of php. just like there is on ms windows to generate thumbnails of images. i can crash windows with having 1 million images in one directory.

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm
Who is online

Users browsing this forum: No registered users and 30 guests