Jump to content

[SOLVED] Error uploading product image


Recommended Posts

Hi !

 

I recently installed prestashop 1.6.0.6 and when I try to upload a product image I receive de following error:

filename.jpg : Server file size is different from local file size

PHP: 5.3.18

MySQL: 5.1.55

upload_max_filesize = 32M;

theme in use: default-bootstrap

Required parameters: Ok

Optional parameters: Ok

 

I haven't modified any file from the server.

 

I tried chmod 777 for img folder and doesn't work.

 

Is this a general bug? Is there any fix for this?

Edited by calinflorin (see edit history)
Link to comment
Share on other sites

  • 8 months later...
  • 1 month later...

Hi,

 

In file classes/Uploader.php at line 179 you have

 

 

I changed to (see below) and worked for me.

 

 

Please try :).

Thank you.

This is bad. Search for better solution, u just removed important security check. My solution was to create folder cache/sandbox. Other theme may have other solutions. Just look why php cant get filesize of a file. Mostly its because file does not exists, because of non existing folder withing some point of a file path.

  • Like 1
Link to comment
Share on other sites

×
×
  • Create New...