Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Color swatches layered navigation

0
votes
0answers
9 views

Color swatches not changing product images in category page in Magento 2

I'm using RokenThemes and integrated the color swatches in category page by adding the catalog_category_view.xml file inside Magento_Swatches/layout inside theme with the below code <...
0
votes
0answers
6 views

magento2.2.5 changing hex code in color swatch?

So I have a magento 2.2.5 CE based website . I have an attribute named color which I enter specific hex color codes for. However I noticed when I click on the swatch box and then click choose color (...
0
votes
0answers
13 views

Product image does'nt change when clicking on color swatch in magento 1.9

I am working on magento 1.9.3. I have used configurable swatches to display color icons. But When i click on color icons, the image in the main product box does not change. I have added simple ...
0
votes
0answers
21 views

How to display specific swatch color button

I´m trying to display only one of the swatch buttons (The color blue) on a specific part of my page. Is there a way to do this? I don´t need it working, I just want it for display. Thanks!
0
votes
0answers
22 views

Unselect Attribute “Is Default” - Color

Magento 2.2.6 The attribute 'color' had, for as long as I can remember, no "Is Default" value selected. A few days ago, I add a new color to the color value. Upon saving, there is now a color value ...
0
votes
0answers
16 views

How to implement my own color swatches in magento 1.9.3

I'm using Magento 1.9.3 version and using Shoppers theme. But i want color swatches. I don't want to buy any extension for that. Is there any tutorial to implement our own color swatches. I am new to ...
0
votes
1answer
26 views

Issue while Configuring color swatches in Magento 1.9.3.10

I am using Magento 1.9.2.10 to configure color swatches i have followed the below link to do this: https://www.templatemonster.com/help/magento-how-to-add-and-manage-configurable-swatches.html#gref ...
0
votes
1answer
22 views

Stop swatches from loading images on product detail [closed]

I have two swatches.. color and size. Is there a way to stop the size swatches from reloading the picture of the product and keep the color swatch working as usual? Ty!
0
votes
0answers
14 views

Magento 2.2.6 on WAMP - Product Attributes will not save Visual Swatches

Process: -Create new attribute -Add Visual Swatches with attached images from import folder and labels -save new attribute Expectation -New values are saved in the product attribute Result -no ...
0
votes
0answers
8 views

Edit background color of mega menu Magento 1.9

I am using Magento 1.9 and I am trying to edit the background color of the megamenu. I navigated all the way to the .scss file but found a $menu-background at the place of the color hex.. where ...
1
vote
0answers
11 views

how to show Color button Options in Product Category Listings page M1

How to show different Color button Options configure Product Category Listings page M1
1
vote
1answer
28 views

Magento2 - Get ID for simple product which is associated to configurable product on product listing page

I want to pass product id in a rel tag in the swatch-option class which is on the listing page for swatches. I am aware it has to be done via swatch-renderer.js but not able to do the code. console....
0
votes
1answer
35 views

In Magento 2, how to bypass cache for a custom block template extended from \Magento\Swatches\Block\Product\Renderer\Listing\Configurable?

Recently I customized category listing page to auto-select the color swatch in listing page when a color swatch is selected in the layered navigation filter. Everything is working fine with cache ...
1
vote
1answer
23 views

How to show swatches on category page in Magento 1.9

I was trying to show configurable color swatches on category listing page but unable to get it, I used below code but it just shows the name of color but I want to show swatches same as on product ...
0
votes
0answers
84 views

Magento 2, how to add color swatches to custom widget template

The custom module lists certain configurable products. I need to display the color swatches, I tried below but it returns nothing! in myTempalte.phtml <?php use Magento\Framework\App\...
0
votes
0answers
18 views

Magento 2.1.14 - Swatches are not generated

I'm loading product images via CSV and set some image as a base, thumbnail, small and swatch. But when I go to the website I can't see my swatches. I see only a blank spot without a color/image. ...
1
vote
1answer
84 views

Magento 2 Get all the colors of a single Product?

How can I get all the available colors of a single product in Magento 2?
3
votes
0answers
64 views

Upload custom images dynamically from product edit page magento 2

I want to create custom image swatches for custom option. There is functionality in magento 1 please check this video. https://www.youtube.com/watch?v=tUvVjvgbJzI I want to develop similar ...
0
votes
0answers
62 views

Change configurable product price selecting a swatch

Good morning, i'm working on a magento 2.2.5 store and i have a question about configurable products configurations. I have some products where the price is different betweent the configurations. ...
1
vote
0answers
67 views

Magento 2 visual swatch not working from changing attribute from drop down?

I have created an attribute "color" with drop-down, now as per our customer request we have changed to visual swatch. and did re-index and flush. but color not displaying at front end as we expected. ...
1
vote
0answers
145 views

How to select by default first swatches from dependent options color & size in magento 2

I have tier prices for the products but it is showing after selecting swatches. I have two attributes "Color & Size" for configurable products. Color attributes have swatch image and Size ...
1
vote
0answers
45 views

Filter the configurable products based on the child product's color in Magento 2

In Magento 2 How to filter the configurable products based on the child product's color. For example, if the parent has 4 children with Green, Red, Yellow and Black colors. If I select green in the ...
0
votes
1answer
17 views

Pass extra class for stock in Swatch Magento2

I want to pass an extra class to swatch class which is formed via swatch renderer js based on the stock. The reason is the swatches are not being hidden if they are out of stock. This is what I am ...
0
votes
0answers
66 views

I have an Issue with “Use Product Image for Swatch if Possible” in magento 2.2

I have an issue with swatch image URL on product detail page. You can check this link for color attribute. Swatch Image url is : ` pub/media/catalog/product\cache\f307e558402b572df42bba27be68d88b//...
1
vote
0answers
26 views

Colour swatch switching back to default randomly [Mage2]

For the past 2 days I've been monitoring my configurable products to see if there is an issue and not to my surprise, I see there is. Basically, I set up a test product with a colour, and checked ...
0
votes
0answers
17 views

Visual swatches not working as expected

Magento2.2 PHP 7.1 I have created one attribute as a visual swatch and added colors to the attribute and then updated the products but on frontend i am not able to see the colors , instead hex-...
1
vote
0answers
39 views

Issue in product image color in magento 2.2X?

I have two swatches i.e., red and black And when a user clicks red colour it changes the colour of the image But in cart the image is base image only. So the issue is, Selected options image isn'...
0
votes
1answer
175 views

Hide base product Images when pick a different color in Configurable Products

what I need is to hide all pics that doesn't bellongs to the selected color in swatch of configurable product, is there any way to achieve this? Thanks. I've seen this similar question, but without ...
0
votes
0answers
191 views

Magento 2 : How to Update Swatch Attribute Text and Image Path

We have configurable products with color, size options. Color is a swatch attribute. Somehow, when we importing our colour options using our custom script, some swatches are wrongly updated with Label ...
0
votes
0answers
33 views

How to show product stock qty after clicking color?

i've got question here and i need assistance : how to show product stock qty after clicking color? example : when i click grey that's stock 5, when i click blue that's stock 3. P.S : this ...
3
votes
2answers
237 views

How to disable a swatch, once it is been selected in Magento2.2?

I am trying to disable a swatch, once after it has been selected. So it should not be deselected... How to do it in Magento2.2.x ?
0
votes
0answers
21 views

Magento 2.1.10: Uncaught TypeError: $element.size is not a functionUncaught TypeError: $element.size is not a function - swatch-renderer.js

i have changed product color attribute from dropdown to visual swacth. And cleared all cache settings under Cache Management. Tested prodcut page add to cart not working.... It shows "This is a ...
0
votes
1answer
363 views

Magento 2 colour swatches not showing on homepage

I have used Magento's default feature for calling New products on homepage. In the list I have a configurable product with visual swatches. But the visual swatches not showing on homepage, can anyone ...
0
votes
0answers
245 views

Magento 2.2.0 swatches sort order not working

Magento 2.2.0 swatch option sorting doesn't working. The issue which exist in all M2 and we don't think they have fixed it still, but the patch isn't also available for latest version. Fix on Magento ...
0
votes
0answers
225 views

Can't change dropdown attribute to visual swatch on Magento 2

I tried to change a dropdown attribute, for color, to a visual swatch on a test magento2 environment but cannot get it working, does anyone have some advice? When I changed the color attribute to a ...
0
votes
0answers
23 views

Mangento 1.9. swatches with same attribute value does not updated

We do have a small magento 1.9 store with configurable products. In our store we have a pens with two attributes for configuration. Body color and ink color. If ink color and body color is both blue ...
1
vote
0answers
322 views

programmatically add color swatches to color attribute Magento2

I am using Magento 2.1.10 and have around 580 different colors in my color attribute. Since the Javascript obviously has trouble showing all of them in the backend (does not matter which browser, ...
0
votes
1answer
398 views

How can I get the HEX code in Visual Swatch via Rest API

Could anyone help me to find the rest api to get hex or image of visual swatch attribute? I need the api to return the following, Label Value HEX or Image of the swatch. Thanks
0
votes
0answers
14 views

Strange behavior using the same class by injecting or the object manager

I have products grouped with children that have an attribute of color swatch, I need to show in our catalog for each pooled product. First, I tried to inject in the construct the class x \Magento\...
1
vote
0answers
396 views

Magneto2 : Add color swatch attribute option with colorcode value programmatically

I am working on Magento 2 and want to add custom color in color swatch attribute option programmatically. I have gone through this post but unable to add options Can anyone helps me to add custom ...
1
vote
0answers
102 views

Magento : Multiple Configurable Swatches on Product Listing Page

I want to show multiple configurable swatches on product listing page. For that I created configurable_category.phtml where I replicated configurable.phtml file to showing the configurable swatches ...
1
vote
0answers
19 views

Magento | Configurable Swatches Tab doesn't appear in The Admin page

I am trying to add a product with color swatches. when I searched I found a lot of articles like this: http://docs.magento.com/m1/ce/user_guide/catalog/product-configurable-swatch.html but I can't ...
0
votes
0answers
80 views

Get attribute swtached values

I have created a custom attribute Product Color and inserted 5 colors. Also created a configurable product with that attribute. Now, I can display that color label in the tab on product view page ...
3
votes
3answers
584 views

How to Auto Select The Color as Swatch Option for Products with Only One Color (on Magento 2.1 Product View)?

I'm trying to have swatch option value of color auto-selected for Products that only have one color. If a user selects some product from the category page, the product page is displayed with ...
6
votes
3answers
1k views

Magento 2 error in swatchRenderer.js at 'updateData' property

I have this error in category page. When i change color from swatch option it star loading in product image container and shows error in SwatchRenderer.js here is the error: Uncaught TypeError: ...
0
votes
0answers
48 views

Related products color swatches crush (Magento 2.1.0)

Want to use color swatches in related products Using this to display color swatches in related section Get the page crash end error log. That i think the main part of error a:4:{i:0;s:178:"Warning: ...
0
votes
1answer
118 views

how to fetch swatch images from another folder ( not from swatches folder )

I have created new attribute color_group. I have added multiple colors to color_group attribute. Now I want to add the color images to that colors. How can I assign color images to that colors.
1
vote
1answer
166 views

Retrieve all the available color in product collection

I have a custom product collection and products inside this collection has variety of colors. I want to retrieve all the colors available inside this product collection and store it in array. $layer ...
0
votes
1answer
112 views

How color swatches work?

Can anyone explain to me how color swatches work when changing images? And where it is done? I want to know where in code it change images.
0
votes
1answer
167 views

Magento 2 - Values required set to no , still get You must choose options for your item

I set to No the Values required and Visible for the size and color from Product Attributes and when I try to add an item to cart , I get this error : You must choose options for your item. What ...