Skip to main content

Category image not displaying properly - PNG

More
15 years 6 months ago #10338 by momentis
I created a PNG of an image I wish to use as a category image (150px X 150px) and added it to the category. However, the image being displayed is just a solid red block, the same color as the text in the PNG itself. In the back-end, when I click on the image itself, the popup shows the correct image. However, in both the front and back-end all I am seeing is a red block.

You can see the issue here:

50.22.11.13/~thegragp/storefront/index.php/shop

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10339 by momentis
If I create a JPG, the display is correct.

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10340 by nicolas
The problem probably comes from the fact that the background of your png image is transparent. Could you set a background before saving it in your image software and then upload it in hikashop ?

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10341 by momentis
I figured that might be it, which is why the JPG worked. However, the default images you have in there (barcode.png) have transparent backgrounds, so I am confused why mine would not work.

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10344 by nicolas
Indeed, HikaShop should handle transparency of png images. Unless your image editing software saves it in a special way that we (or the GD library that hikashop uses for images resizing) do not support. For example, if you use a special color for transparency instead of the default one, that might cause such issue I think.

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10348 by momentis
I will have to check. I generated the PNG in Photoshop. I will do some further testing and let you know what I find!

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10351 by momentis
No matter what I try, I cannot get this issue to resolve itself. I am creating a transparent PNG in Photoshop, using the default transparency. I am saving it out as a PNG-24 using the regular Photoshop defaults. I created the image at 125x125, which is the size set for thumbnails in the Configuration file, so no resizing should be necessary. I still get the red block, which is layered on a white background, even though the image itself is 125x125. Weird!!

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10352 by momentis
Image Info:
Format: PNG-24
Dimensions: 125w x 125h
Size: 4.09K
Settings: Non-Interlaced, Transparency on

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10353 by nicolas
Did you try with a different bit ratio ?
8bits maybe ?

Could you try to replace the file administrator/components/com_hikashop/helpers/image.php by the one in the archive enclosed (make a copy before in case it doesn't work) ?
I changed a bit the code for the transparency handling...That might just do it.

This attachment is hidden for guests.
Please log in or register to see it.

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10354 by momentis
I did try 8bits, but it didn't make a difference. I will try your changed file and post my results. Thanks!!!!

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10355 by momentis
No change with the updated file. Sorry!!!

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10356 by momentis
Just so you know, this really is NOT a huge deal!!!

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago - 15 years 6 months ago #10357 by nicolas
I tried with your image on my end and got the same result. I tried to save your image with paint.net and I got the logo under a black background. I also tried with a watermark with your original image and what's funny is that the watermark was below the logo but in front of the red block...
I don't know what the problem is, but there is definitely a problem with the image format which is not handled properly somewhere.
Last edit: 15 years 6 months ago by nicolas.

Please Log in or Create an account to join the conversation.

More
15 years 6 months ago #10358 by momentis
Ha!! I guess I really did a number on it! Oh well, if you come upon a resolution - great. If not, no big deal. I will just use a standard sized JPG for my category images. Thanks, nicolas!

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #159658 by RedPlugDesign
I had the black outline image also. I realized that when i used 3rd party software to compress, it resulted in the black background or outline

Please Log in or Create an account to join the conversation.

More
12 years 3 months ago #159663 by Eliot
Thanks for your feedback, I'm sure it will help people facing the same issue ;)

Please Log in or Create an account to join the conversation.

Time to create page: 0.361 seconds
Powered by Kunena Forum