Jump to content

Why can't I upload an Image?


Recommended Posts

Hi

 

I was trying to upload an image with a file size of 20.7KB but i can't do it. Why is that so?

 

I am creating a new category where they have this browse button and I search for my picture. While I save it, it said error occur while saving the image? Can someone advise? Thank you.

Link to comment
Share on other sites

Hi firecorpz,

Please open your config/config.inc.php file and replace

@ini_set('display_errors', 'off');
define('_PS_DEBUG_SQL_', false);

with

@ini_set('display_errors', 'on');
define('_PS_DEBUG_SQL_', true);

and then refresh the page. You should be able to see whatever error is preventing you from properly uploading your images.

 

Please let me know what shows up.

 

-Mike

Link to comment
Share on other sites

OK, so open the config folder on your FTP and right click the config.inc.php file, and then choose "view/edit."

 

Once the file is open, look for the code I mentioned earlier, which should be right around line 29 for you. Just replace it with the version I provided, save the file and then save it on your FTP as well.

 

What this will do is show you the error log when you try to upload the image again, and that should give us a clue as to the problem you are encountering.

 

If you have any additional questions on this, please let me know, and otherwise post any errors you get here so that I can continue to help you resolve this!

 

-Mike

Link to comment
Share on other sites

I try to upload the pic again nd this is the message

 

Warning: imagejpeg() [function.imagejpeg]: Unable to open '/home/bigmanc/public_html/img/c/52.jpg' for writing: Permission denied in /home/bigmanc/public_html/images.inc.php on line 308

$(document).ready(function() { $('#hideError').unbind('click').click(function(){ $('.error').hide('slow', function (){ $('.error').remove(); }); return false; }); });

close.pngerror2.pngAn error occurred while uploading image.

Link to comment
Share on other sites

I try to upload the pic again nd this is the message

 

Warning: imagejpeg() [function.imagejpeg]: Unable to open '/home/bigmanc/public_html/img/c/52.jpg' for writing: Permission denied in /home/bigmanc/public_html/images.inc.php on line 308

$(document).ready(function() { $('#hideError').unbind('click').click(function(){ $('.error').hide('slow', function (){ $('.error').remove(); }); return false; }); });

close.pngerror2.pngAn error occurred while uploading image.

 

In your FTP's root folder, can you please find your images.inc.php file, right click on it and select file permissions, and then tell me what you have for the current permissions value?

 

-Mike

Link to comment
Share on other sites

Hi Mike,

 

it getting late over here in SIngapore

Need to take some rest, can I contact you again regarding this matters ?

 

Sure, although we're on the East Coast so I may not be able to help you until Monday morning depending on when you send it. But I will make sure to help you with this.

 

-Mike

Link to comment
Share on other sites

Hi, I'm also having problems with image import.. I guess my problems might be related to the fact that FTP server from which I want to import images requires FTP password and username.. Where should I specify these details before importing pictures?

Link to comment
Share on other sites

  • 2 weeks later...

Solution here is one, bc u don't have much exp in this, just find good specialist on freelance who help u with ur server config. Ur problem not in prestashop, ur problem in bad server config.

 

Don't forget that files on FTP have user:group also, not just file permissions like 644/744/777 etc. Mb ur server config check not only permissions but also file owner and if file owner not server, he can't change it.

 

If u can post here php info from ur server, made info.php in site root with text:

 

 

<?php

 

phpinfo();

 

?>

 

And using ur favorite browser go on www.yoursute.com/info.php

Link to comment
Share on other sites

×
×
  • Create New...