Questions tagged [product-images]

Denotes questions related to product images configuration, management and modifications.

Filter by
Sorted by
Tagged with
0
votes
0answers
7 views

How to Display Product Images by Image Role

I am trying to figure out how to display product images by their image role inside Magento_Catalog/templates/product/image_with_borders.phtml Each product on my shop page will have three images each ...
0
votes
0answers
7 views

Is there a way to automate catalog:images:resize after a product import?

First off, all product data is being imported in to Magento. I know it's an issue that the images cache isn't created so after the import products show placeholder images and we can fix this by ...
0
votes
0answers
15 views

Magento 2 - How to use simple product images for configurable products when no configurable product image is uploaded?

How can I use the simple product image for configurable products where no configurable product image is uploaded? Currently I can see the placeholder image unless options are selected. I set up ...
0
votes
0answers
19 views

Images not displaying in correct order for configurable product in magento 2.3.3

The images for the configurable product dont appear in proper order as in backend. See https://prnt.sc/128ldmw and https://prnt.sc/128leye I want to display them in the same order as they are in the ...
0
votes
0answers
11 views

Resizing Zoomed image on Product Page

I am needing to resize (reduce) the zoomed product page image. After clicking on the image and the popup image opens, it fills the whole page. I need to reduce the size to where it is not so large, ...
0
votes
1answer
22 views

How to resize product images without magento resize commands

We have magento setup with magento version 2.3.5-p2. Currently it is showing product broken product images. After running resize command bin/magento catalog:images:resize, product images are working ...
0
votes
0answers
19 views

Assigning Thumbnails via Magento REST API

I am trying to add thumbnail images to SKUs via REST API. However, the image is added but does not show as a thumbnail. Please see my POST request below https://url.co.uk/rest/V1/products/231877/media ...
1
vote
1answer
37 views

Magento 2 set child product image from URL

Magento 2.3.5 How to set child product image from URL for configurable product on the product detail page Example - product URL is - http://xyx.com/product.html#447=5439 dropdown is selecting ...
1
vote
1answer
37 views

magento 2 Uncaught TypeError: Cannot read property 'data' of undefined [closed]

Magento 2.3.5 getting error on the product detail page of configurable product - Getting this error - Uncaught TypeError: Cannot read property 'data' of undefined at Object.returnCurrentImages (...
0
votes
0answers
29 views

Magento 2.4.2 How to hide duplicate pictures when the product color is switched

When the product is configurable, the default picture will be displayed repeatedly when switching colors. How to hide duplicate pictures when the product color is switched. ---------------------------...
0
votes
0answers
12 views

How to show a higher quality image in Magento2 Gallery Fullscreen

I want to load the product_page_main_image (which is larger) rather than the product_page_image_medium when you click the Fotorama Gallery. This will give me a higher quality image because it's ...
0
votes
1answer
25 views

How can I load image through api by using external image url?

I have my product images in my cloud store and those are public. I want to map those images to product through API. I have gone through the solution given in the below link. But I want to check if ...
0
votes
0answers
34 views

Fotorama zoom_in and zoom_out buttons are not working in Magento 2.3.6

The zoom_in and zoom_out buttons are not working in the product pop-up gallery, however, while clicking the image, the image gets zoomed on the first double click and gets zoomed out on the second ...
0
votes
1answer
29 views

Magento 2 - Fotorama Gallery Nav shaft is missing on product page

If you add multiple images to a product then they are showing below the base image in small boxes, see screenshot below (bottom corner - left): This box is missing. First I thought it is because some ...
0
votes
0answers
31 views

How to show all images on product page M2

I'm trying to show all images on the product page like this but I still need to keep the zoom functionality and carousel for mobile. Is this possible whilst using fotorama?
0
votes
2answers
32 views

Assign images to products programmatically

I want to assign images to products in my store. The images name the same SKU product name. I put my PHP file in root/pub and tried this code: <?php ini_set('display_errors', 1); ini_set('...
0
votes
0answers
14 views

How Can I Change Dimension Of Gallery Thumbnail Image Product Detail In Magento 2?

I Need Make That Image Small. How Can I Change Dimension Of Gallery Thumbnail Image Product Detail In Magento 2 That's Gallery Thumbnail Image Need Small It Any One Help Me.
0
votes
1answer
30 views

How To change Product Detail Page Image Section Height In Magento2?

How Can I change Product Detail Page Image Section Height. I Need To Decrease That Section Height. i need to fixed this left column height as right column in magento 2 can any one help me how can i ...
0
votes
3answers
36 views

Not able to get product image

How to get product image in "default.phtml" file ? Magento2/vendor/magento/module-sales/view/frontend/templates/email/items/shipment/default.phtml I am getting the shipped product object in ...
0
votes
1answer
24 views

Product Images not showing - Magento 2

I am experiencing a strange issue with Magento 2 when creating new products where the product images shows fine in the backend, it also shows on the frontend category catalog but on the actual product ...
0
votes
1answer
21 views

Image resize issue

I am uploading below image for the product via backend. But it changes to below image It is clearly visible that it changes the color. I have tried using ImageMagik also. I have even tried this ...
0
votes
0answers
20 views

Magento 2.3.3 Customer order view page break after product delete from system

I placed order and after that same product i had delete after that. When click on view order link from customer order page , below error displayed. Fatal error: Uncaught TypeError: Argument 1 passed ...
0
votes
0answers
26 views

How to get image url in magento 2 on checkout page

How to get image url in magento 2 on checkout page custom phtml file. I created the custom phtml. I need to get the product image in that phtml file
0
votes
0answers
10 views

How to Get Gallery Resized Gallery Images in Product list

<?php $i = 1; $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $product = $objectManager->create('Magento\Catalog\Model\Product')->load($_product->getId()); $images = $...
0
votes
0answers
9 views

Product image files being added more than once (_1, _2, _3, etc.)

So this is odd. I've noticed this since 2.3.x (I'm now on 2.4.1) but it is getting annoying and I'm wondering if anyone knows why it does this (and hopefully a fix? Or how to stop it from doing this). ...
2
votes
0answers
22 views

Resize different images to square without white space

I am trying to force all the images in the product grid to square. The database serves images from ultra wide to ultra high ratios. i'm trying the following: $productImage = $imagehelper->init($...
0
votes
0answers
11 views

Magento 2 Commerce Edition custom theme product image not showing on home page

The product image showing on Both PLP & PDP page, when i try to add on home page by using widget is not visible, the name and price showing but image missing, I am creating custom theme from blank ...
0
votes
0answers
15 views

How can i add a function to scroll product images in the catalog search list page?

so... i have been trying to solve this situation for a few days now... In theory, it should not be difficult to solve... But i cant find the right way to do it... If i search for a product... i am ...
0
votes
0answers
18 views

How to set image for product on catalog_product_save_after event in magento 2?

I am able to set quantity after product save but not able to figure out how to set a product image on catalog_product_save_after event. Any help
1
vote
2answers
92 views

Magento 2 how to override theme-adminhtml-backend view.xml in custom module?

By default Magento 2 creates more than 20 duplicates of each product image..! (why???) I have got this down to 5 using view.xml in my theme, but there is one extra set of image sizes I need to change, ...
0
votes
0answers
14 views

view.xml Fotorama gallery thumbnail sizes @2x?

I just want to increase the size of the gallery thumbnail images, but then set their display size smaller via css to achieve high resolution display. (The default display is 1x which is noticeably ...
0
votes
0answers
28 views

Magento 2 set product image role programmatically

Hello and this is my code: $imgURL = 'path/to/my/image.png'; $fileSystem = $objectManager->create('\Magento\Framework\Filesystem'); $mediaPath = $fileSystem->getDirectoryRead(\Magento\Framework\...
0
votes
1answer
42 views

reindex command generates error: Argument 2 passed to Magento\Catalog\Block\Product\ImageFactory::getLabel()

When I run reindex command bin/magento index:reindex catalog_data_exporter_categories I get the following error on console. Argument 2 passed to Magento\Catalog\Block\Product\ImageFactory::getLabel() ...
0
votes
2answers
26 views

Magento2 - How to get Image Size?

For Image optimisation, I want't to get Product Image Size. (Either in KB or MB etc.) Ex: 6 KB, 6KB,5KB etc. I am using following code on root path. <?php error_reporting(1); ini_set('...
0
votes
1answer
20 views

How does magento product image caching works?

I uploaded some images to my products and they were visible fine on frontend. I then went and deleted those images from pub/media/catalog/product folder and also deleted pub/media/catalog/product/...
0
votes
0answers
16 views

Placeholder Image not showing in frontend

I was using cdn for media intially but then later replaced it to pub/media/. I dont have any product images with me, hence I uploaded placeholder images from admin. The products still load from pub/...
3
votes
1answer
49 views

Magento 2 : Custom API code to upload multiple product images programmatically

I am making custom Magento API to create products. I can make products using custom API. Now my requirements is to upload multiple images to that API. Can anyone helps me for reference code to upload ...
0
votes
1answer
39 views

Data migration issue : SQLSTATE[23000]: Integrity constraint violation from maento 1.9 to magento 2.4.1

I am migrating the data from Magento 1 to magento 2.4.1 by running the following command php bin/magento migrate:data --reset vendor/magento/data-migration-tool/etc/opensource-to-opensource/1.9.0.1/...
0
votes
1answer
30 views

How to migrate product images before using Data Migaration tool from magento 1 to magento 2

I wish to migrate data from magento 1 to magento 2 using data migration tool. I know the procedure for migration using data migration tool. But i am having doubt on, how to migrate the product images &...
0
votes
0answers
20 views

Magento 1.9 - Getting exception while uploading product images

When I'm trying to upload product images in backend and save, getting below exception in debug file - 'Zend_Db_Statement_Exception' with message 'SQLSTATE[42S22]: Column not found: 1054 Unknown column ...
0
votes
0answers
45 views

Magento 2- Why for some products only one image roles are showing?

I'm using Magento 2.1.11, We noticed that for some SKUs only one image role is showing i.e. base image (Attaching screenshot below) other image roles are not showing. I tried setting them ...
1
vote
1answer
103 views

Magento 2 - get cache url of media gallery images of product

This is my code for get cache url of images: $images = $_product->getMediaGalleryImages(); foreach($images as $child){ echo '"'.$child->getUrl().'"'; } Result expected: ...
0
votes
0answers
23 views

create custom product image attribute in magento 2

I have to add the custom image attribute in product attribute. I referred this link: create product image attribute in magento2. but image saved in my temp directory after saving the image how can we ...
0
votes
0answers
22 views

Magento 2 Product Page Gallery Image Preview showing same image

Im facing a serious issue with Magento 2.36 product view image gallery. The Preview thumbnail images are showing same if there are multiple images. The issue seems to be a conflict with Algolia ...
0
votes
0answers
27 views

Image color shift after uploading to Magento admin

When I upload any product image, that images change his saturation and color This is the original image: This is the image post uploaded: I'd searched on Google about this error, and the most ...
0
votes
0answers
19 views

Magento 1.14 Image upload from admin panel throwing 404

I am working with the Magento EE 1.14 site, recently I've installed the patch(11295), after installed it, I am facing issue while upload the product image from back-end. I've reviewed the code changes ...
0
votes
0answers
7 views

Magento 2.3.6 - How to Bulk change existing & new Product image file name for SEO

How can I change the filename of existing & new product images as per SEO instead of just sku type names. I noticed some similar threads here, but those are for Magento 1. Can anyone pl help me ...
0
votes
0answers
16 views

Watermark issue

Currently we are running on Magento 2.2.6. We have added a watermark for the base, thumbnail, swatch & small. The watermark is appearing on the productlist page, but not in a good manner, see ...
0
votes
1answer
19 views

Magento Command for bulk Optimizing existing Product images

How to optimize existing Product images via commandline, similar to resize command. php bin/magento catalog:images:resize https://docs.magento.com/user-guide/catalog/product-image-resizing.html This ...

1
2 3 4 5
25