Questions tagged [compare]

Questions about the "compare products" feature. Do not use this tag for questions about comparing anything else.

52 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
2
votes
1answer
100 views

Magento 2 API for product add to compare and compare list

There is any way to get API for product add to compare and get compare list for customer. Thanks
2
votes
0answers
50 views

Magento2.3: Compare slider is not working

We have customised the compare products as per our requirement. However, Its not working as expected. I'm not sure, whether the data binding is working or not. For your information, I'm using slick ...
2
votes
0answers
2k views

Check if there are any products in the compare list in Magento 2

I'm using Magento v 2.2 and I'm trying to check if the customer/visitor (doesn't matter if logged in or not) has any products in their compare list and I'm trying to do this in {theme_dir}/...
2
votes
0answers
22 views

Compare Magento repository and production

I have to compare my production vs repository because there are much difference between both, but I do not know how to compare all files. Please suggest me how to do?
1
vote
1answer
76 views

Magento2 Rest API for add to compare

Magento2 - PWA. I am developing PWA in Magento2. In products I am not able to see Add to compare link. How can I create add to compare REST API & use it in PWA?
1
vote
0answers
47 views

Get compare product collection on CMS, Catalog Pages

I have used the below code but that is not working on catalog, cms & product page for me. but for compare page, cart page, and checkout page it's working. $objectManager = \Magento\Framework\...
1
vote
0answers
100 views

Magneto2.3.1 How to customize checkbox with compare link display on product detail page

I am using Magneto2.3.1 and i need to customize the default magento compare link on detail page. I want to show checkbox with compare label and if i checked than product compare successfully and if ...
1
vote
0answers
227 views

Magento 2 compare only those products which are having same parent category?

anyone having an idea how to compare only that category which is having the same parent. for example, a customer can compare Samsung washing machine with LG washing machine but if customer wants to ...
1
vote
1answer
133 views

How to change position of attributes in compare products

Magento 2.1 in the "More Information" of products page position. It's okay but when I compare position it incorrect such as the product page attribute positions 1 2 3 4 but in compare 2 3 4 1. 1 is ...
1
vote
0answers
604 views

Magento 2 - Compare product Count and Compare product URL Not working?

In Magento 2, I am not getting compare product count on adding the product to compare list even it does not redirects when I click on compare product button in header location. Kindly Suggest.
1
vote
1answer
248 views

How to add “Compare List” into cms page?

I tried to add compare list into cms page, but it doesn't work {{block type="catalog/product_compare" template="catalog/product/compare/list.phtml"}}
1
vote
0answers
308 views

Magento 2.1.2: How display products compared with the popup - AJAX

I have this code - custom module Ajax: _CompareAction : function(){ $('body').on('click','.action.compare',function(e){ e.preventDefault(); var href = $(e....
1
vote
0answers
731 views

Products are not adding in compare list in magento2?

I have to implement product compare feature in my magento2. For this i am using <?php $this->getAddUrl($product); ?> and I am getting the compare url of the product. But after click on add ...
1
vote
0answers
86 views

How to export Compare product list in PDF formate in magento 1.9?

I want export Compare product list in PDF. i am using magento 1.9. someone knows answer please help. thanks in advance.... following is my list.html file. <div class="comparison-div"> <?...
1
vote
1answer
483 views

Adding attributes to “list.phtml” for compare page

I want to show all attributes of a product in compare page. I added this code in catalog/product/compare/list.phtml but I get this error: <h2><?php echo ( ( $_item->...
1
vote
1answer
476 views

Magento Products Compare limit

I want to set a max amount of products that can be added to the compare list. I want to set the max at 3 products that can be compare. Tried this code: Step1:Create config.xml at app>code>local>...
0
votes
0answers
16 views

Magento2 messages is not getting added & not getting displayed

Magento2 error message is not getting displayed, it gets displayed only after page refresh. I checked in console, the error msg is not getting added in messages: public function aroundExecute( \...
0
votes
0answers
14 views

magento2.4 how to check on listing page if the product is already in compare list or not, or get list of products in compare list?

I need to get the know on list page whether the product is already in compare list or not, else get the list of products already in compare list. I tried the code in below link but getting blank array ...
0
votes
2answers
32 views

Magento2 display header compare link after custom block in header

Magento2 move header compare link after custom block in the header I have added custom block in header as follows <referenceContainer name="header.topcontent"> <block ...
0
votes
0answers
11 views

Compare page print pdf magento 2.3.3

Can anyone tell me where is the code written for Compare page Print https://prnt.sc/vmmvgr. The print page is totally messed up.Can anyone help me on this. I need to remove header and footer from the ...
0
votes
0answers
17 views

Magento2 product added to comparison message in Modal popup

Magento2 product added to the comparison message in Modal popup. I need to display message in modal popup
0
votes
0answers
30 views

Magento2 modify success message of add to compare products list & display it in popup

Magento2 How can I modify the success message of add to compare products list You added product Urban twist 2 to the comparison list. & display it in popup modal
0
votes
0answers
28 views

Magento2 get Visual Swatch colors on Compare product list page

Magento2 I need to get the Color Swatches option on Compare products list page. When a config product is added to cart I need to display it swatch Images. How can I achieve this?
0
votes
0answers
13 views

Magento2 fetch value from catalog_compare_item table

Magento2 How can I get the value of following table 'catalog_compare_item' using a model or any other proper way of Magento?
0
votes
0answers
29 views

How does Magento2 handle compare products for Guest Users?

Magneto2 I would like to know how does Magento handles compare products for Guest User. I am creating a Rest API to add the product to compare products. But for Guest User how am I suppose to restrict ...
0
votes
0answers
39 views

Magento2 How to move add to compare product from guest user to login user?

Magento2 Rest API & PWA. Using PWA I want to allow the user to compare products. I added the product to comparison programmatically. I am facing 2 issues For Guest User, how do I stop the user ...
0
votes
0answers
14 views

compare product block display left sidebar_additional block in magento 2.3.5

how to compare products block define and call in our theme in magento 2.3.5 Now Please check our xml file app/design/frontend/Mageplaza/simple/Magento_Theme/page_layout/2columns-left.xml <?xml ...
0
votes
1answer
394 views

Magento 2 check if product already in compare list

I want to check if products is already in compare list on product listing page and show remove compare button there below is come of my list.phtml Add to compare <a id="compareclick-<?php ...
0
votes
1answer
59 views

Magento 2: Product page compare product add in new tab

I am using magento 2.3.3 in custom theme and I want to compare products add in new tab how can achieve this? Thanks in advance
0
votes
1answer
549 views

Magento2 How to get current compare product collection on product list and product detail page?

I am using Magento2.3.1 and I need to list and detail page current product if add compare product than getting list and count on list and detail page. So I try to detail and list page checkbox with ...
0
votes
0answers
108 views

Compare products id in magento 1.9

Is there any way to select only product Id for compare items in collection Like: $compare = Mage::helper('catalog/product_compare')->getItemCollection(); $compare_product = array(); $compareList = ...
0
votes
1answer
23 views

Retrieved compared products list in homepage

I like to retrieve compared product collections in homepage template. Is there any method to retrieve the data?
0
votes
0answers
55 views

Compare() link to be placed in dropdown menu in magento 2.3

I want to place the Compare link inside the dropdown below Wishlist in header links as shown here OR https://prnt.sc/os1u0o. Can any one tell me how to do that ?
0
votes
1answer
42 views

add to compare doesn't work

When I want to add a product to compare list I get the error "page not found". The wishlist works fine, if I access the link from "mydomain/catalog/product_compare/add" it is redirected to "mydomain/...
0
votes
1answer
69 views

compare images from catalog_product_entity_media_gallery with actual presence on server

So, In our catalog_product_entity_media_gallery table in the Magento 2.3.1. database are around 25.000 lines. Like: 18963,90,/_/_/__1_3.jpg,image,0 18965,90,/_/_/__1_4.jpg,image,0 10815,90,/_/_/__1....
0
votes
1answer
431 views

Retrieve Compare Items Collection returning zero Items Magento 2

While I am trying to return compare items in custom module phtml file, it is returning zero items but in database table catalog_compare_item showing all the added items to compare. Class Used : ...
0
votes
0answers
25 views

Magento2: Custom comapre button functionality

How to add custom compare button with check-box. The page should be not refreshing. Please check below screenshot My Magento v2.0.17
0
votes
1answer
491 views

How to get product's comparable attributes list by product id

I would like to know, the process to get list of comparable attributes of a product with their label/name and their values. i'm using this, but it's not working. $attributes = $objectManager->...
0
votes
2answers
160 views

How to call Plugin which already using the preference for vendor file in magento 2

How to call Plugin which already using the preference for vendor file in magento 2. I have already has preference which is overridding the some custom Magento controller, Now how can i use plugin to ...
0
votes
1answer
78 views

Empty getAddToCompareUrl only in guest mode

I have this variable $_compareUrl=$this->getAddToCompareUrl($_product) to get compare url but this is empty in guest mode, only when i signed in magento it's not empty. I recently migrate from ...
0
votes
1answer
940 views

How can I remove wishlist and compare block pieces form the 404 not found page?

I need to remove wishlist and compare from the not found page. I use CMS to make the not found page. This is what I tried as a Design XML Update, and it didn't work: <referenceContainer name="...
0
votes
1answer
331 views

How can I get compare button in header section with the same functionality as of cart button

I'm an IT student and new in magento. I was wondering, how can I create compare button as on that link http://ultimo.infortis-themes.com/demo/ I found sidebar.phtml file under vendor/magento/module-...
0
votes
0answers
56 views

Add To Cart Button have not press event

I am new to magento 2.1.. I have a problem to show the products.Product is shown in that page but the issue is the when i am pressing add to cart button it is not pressing also same problem in add to ...
0
votes
0answers
97 views

How to send compare product list via email in magento 1.9?

I want send compare product list via email in magento 1.9. i have tried this link Email Compare Product List but not works for me. following is my list.phtml file <?php <div class="page-title ...
0
votes
1answer
735 views

Magento2: Why does the Compare Products sidebar on category pages not show up, but return when I delete a certain layout file? See further explanation

The Compare Products sidebar on category pages does not show up, and I was trying to figure out why. So I temporarily deleted files under the app/design/frontend/customer-name/default folder to see if ...
0
votes
1answer
200 views

how to display attribute group set on compare list page on frontend?

I want to display Attribute Group set Name on frontend of compare page. i tired due to searching. anybody knows how to make attribute group set on compare product page list. please help. your help be ...
0
votes
1answer
453 views

How to view related products for all products in compare list?

I want to add the related products block to the compare list, however I am getting a fatal error Call to a member function getRelatedProductCollection() on a non-object. I suspect this is because I ...
0
votes
1answer
540 views

Compare and wishlist link doesn't work

I need to add compare and wishlist link in to the 1column.phtml file. I added this code in this page but nothing show!!! app/design/frontend/default/celebrity/template/page/1column.phtml For compare ...
0
votes
1answer
467 views

How to display Attribute Group Name on compare page?

I used this guide and was able to display the attribute group name on the product page, but I'm wondering how to do the same on the compare page ? I'm using magento ce 1.9.2.1 with custom Porto theme ...
0
votes
1answer
149 views

Product compare list empty on costum module page

At header.phtml I load the product compare list with the following code: $collection = $this->getLayout()->createBlock('catalog/product_compare_list')->getItems(); On default pages like ...