Jump to content

[Solved] Black Background


Recommended Posts

If you have a problem with black backgrounds when you have uploaded your product images.

Replace this file ive attached on your installation and it will change it back to white again!

Its found directly in the root of your prestashop installation!

After replacing the file have to regenerate your thumbnails with the function in Back Office

Preferences/Images/Regenerate

The error seems to be in coding for PHP 5.2.8

Best regards Robin

images.inc.php

Link to comment
Share on other sites

  • 2 months later...
  • 1 month later...
  • 5 weeks later...

open the images.inc.php with an editor like notepad++ and replace all jpg with png. Then regenerate the thumbnails.

All the resized pictures will have a transparent background.

ups, your post is one month old....

Link to comment
Share on other sites

Hi Guys,

I appreciate your suggestions, but none are working for me - does anyone have any further advice on how to solve the 'black box' problem?

Tried copying the new code
Tried changing jpg to png

Presta Version 1.2.1.0 -0.034s
PHP5 5.2.10
MySQL 5 5.0.82

Need a solution quickly - about to launch...

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...
  • 3 weeks later...

Hi,

I use the file sent by Style on the "problem with picture background" topic, and replace all the "jpg" to "png" and I have nice pictures with transparent background !!

Thanks everybody for giving these fixes !

However, even if the files are transparent, they have '.jpg' extension... does anyone know how I can change this?

Cheers

PS: attach is the final file

images.inc.php

Link to comment
Share on other sites

  • 2 weeks later...
  • 3 weeks later...

I installed Prestahop for several people on the same server. The black border problem occured suddenly on all the webshops. I could be wrong but it seems like the black border issue started after a PHP upgrade on the hosting server (PHP 5.2 to PHP5.3).

The solutions I find here are OK but have not the same result as the original images.inc.php

Transparent background is blury (see http://www.aludoor.be - 3th image on featured products) before this would be smooth or white ?

I also think that the new images.inc.php resizes the pics in a different way. I had to resize the thumbs below the product image on the product page to 78 px wide to have some white space between them.

When resizing the images on an 1.2.0.8 shop (after changing the images.inc.php file) the admin panel hangs after a while.

When using the images.inc.php file downloaded from the forum it is a solution for the front end but in the admin catalog the thumbnails are big pictures.

If it is a problem with server upgrade to PHP 5.3 maybe it is worth looking a little deeper into this problem ?

I still need a solution.

Cheers

Link to comment
Share on other sites

  • 8 months later...
If you have a problem with black backgrounds when you have uploaded your product images.

Replace this file ive attached on your installation and it will change it back to white again!

Its found directly in the root of your prestashop installation!

After replacing the file have to regenerate your thumbnails with the function in Back Office

Preferences/Images/Regenerate

The error seems to be in coding for PHP 5.2.8

Best regards Robin



i have tried but have some error with permission, how to solved this problem? sorry i'm newbie in programming

30620_ZrPqQpZTo3HtoW4rwTi6_t

Link to comment
Share on other sites

  • 2 months later...
  • 3 weeks later...
  • 1 month later...

Same situation here.
We never touched our image.inc.php and all at a sudden the small thumbs get resized with black background (instead of white as specified in that file).
If we try using Karoko's file we get "Error when trying to copy the image".

Any help appreciated!

Jose

Link to comment
Share on other sites

  • 4 months later...
  • 2 weeks later...

Hi all, i installed the file and regenerated my images. I then received the same error as: exerberry above, then i decided to go to my ftp and make the file permissions 777, i then lost most of my products images ( if not all). How do i make sure that don't lose the images after regenerating?

Link to comment
Share on other sites

×
×
  • Create New...