unlimitedgrain Posted June 11, 2015 Share Posted June 11, 2015 Hi all, I need some help. I'm trying to understand the folder structure of the imp/p folders. we upload images as png because we need the transparancy. If we use jpg we get white borders on images that are not square and this we don't want. On the server I see only jpg images, so the first question is: where are the png images saved? Second I thought the structure is as follows: if the product-id is 743 than the images are saved in imp/p/7/4/3 This is not the case. Images i find there are from another product. Also we have products with 2 digits, like 11. There are no images in imp/1/1 but only folders. So how is the structure so I can find a product image? Also we have 2 images with each product, the images I find on the server are only the second images of products. So where are the main images? The second images are jpg, the main images are png. Here is a link to our website: https://www.artupfront.com/ Thanks for your time!! Link to comment Share on other sites More sharing options...
bellini13 Posted June 12, 2015 Share Posted June 12, 2015 if the product-id is 743 than the images are saved in imp/p/7/4/3 Every image has its own unique ID, so the number you are seeing is the image id, not the product id. Link to comment Share on other sites More sharing options...
unlimitedgrain Posted June 12, 2015 Author Share Posted June 12, 2015 Every image has its own unique ID, so the number you are seeing is the image id, not the product id. I figured that out, but where are the original png images? Also, the system makes a watermark image. We don't use a watermark. Can someone confirm it is save to delete this image? (because of the large amount this will save us a lot of disk space) Is there something I can do so this watermark image is not created anymore? thanks!! Link to comment Share on other sites More sharing options...
bellini13 Posted June 13, 2015 Share Posted June 13, 2015 Also, the system makes a watermark image. We don't use a watermark. Then disable it. You should be able to search on how to do this Can someone confirm it is save to delete this image? (because of the large amount this will save us a lot of disk space) If you delete the original image, then you will not be able to regenerate your product images in the future without uploading the original again where are the original png images? you already stated that they are converted to JPG Link to comment Share on other sites More sharing options...
parsifal Posted June 14, 2015 Share Posted June 14, 2015 (edited) On the server I see only jpg images, so the first question is: where are the png images saved? It's a dirty "trick" that PrestaShop uses: the images are PNG really, but with a "fake" .jpg extension. Browsers have no problem with this (they depend on MIME type, not extension, to render an asset) and will still happily display such images. That's what PS depends upon to get away with such a trick. The reason why this trick is needed? I'm not entirely sure, but I would guess it has something to do with URL rewriting for images. PS: On Windows, I use the lovely IrfanView application as my default image viewer. If you download such a ".jpg" file and open it with IrfanView, it will display a warning that the file is really a PNG with incorrect .jpg extension and offer to rename the file with a proper .png extension. You can try this yourself to make sure that your image files are really in a PNG format. Edited June 14, 2015 by parsifal (see edit history) 1 Link to comment Share on other sites More sharing options...
unlimitedgrain Posted June 16, 2015 Author Share Posted June 16, 2015 Thanks bellini13 and parsifal This clarifies a lot. Looking at problems some of the users have after regenerating images I don't want to do this and end up with issues on the images. The images are our products (we sell art) so the most important. Looking at your answers I can savely delete the watermark images from the server I think? Thanks parsifal for the telling about the exptensions, I was very puzzled by it. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now