Questions tagged [layered-navigation]

Layered navigation makes it easy to find a product based on category, price range, or any other available attribute.

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

Magento 2 Layered Navigation Active on desktop but closed on mobile

Currently all the items in the layered navigation are active in desktop and that's how I want it to display but for mobile I would want them to be all closed and open on click. How can I achieve this?
0 votes
0 answers
32 views

Magento 2 : Apply filter layered navigation in REST API

In frontend side, layer filter apply because of this below code. But, how can i use this below line into rest api as well? Is it possible to get $this->getRequest() object into rest api? Below code ...
  • 17.1k
1 vote
0 answers
17 views

Magento 2 - Categories in Layered Navigation

My layered navigation is not displaying categories in a filterable manner, screenshot below. Currently every category in my tree is set to anchor and when I go to a given category page, all the ...
0 votes
1 answer
42 views

I need filter products by discount percentage in layared navigation (category page)

I have applied several price cart rules, I would like to see those frontend rules that work as a filter for discounted products. Someone can help me?
0 votes
0 answers
46 views

Magento 2.4.3 - Layered Navigation - Categories

How can I go about setting up my layered navigation and category tree so the displayed products can be filtered by which child category they are in? I currently have every category in my tree is set ...
0 votes
1 answer
20 views

Can't access terms and condition from amdin panel

I try to access terms and condition from admin panel but I get the following error Error: Cannot instantiate interface Magento\Catalog\Model\Layer\FilterableAttributeListInterface in /var/www/html/...
0 votes
0 answers
28 views

Magnto 2.4.5 Configurable product options are showed separately on Layered Navigation Category Filter

after upgrading to Magento 2.4.5v in the Layered Navigation Listing, configurable products are shown separately. All configurable options are shown as simple products separately even are selected as &...
0 votes
0 answers
84 views

Magento 2.4.3 - Anyone that has experience with Porto theme?

Is there anyone that has some experience with the Porto theme and can give me a hint on how I can get a 3rd party layered navigation to work properly with Porto Theme? I can see they have added ...
0 votes
1 answer
45 views

How to enable 'Use in Layered Navigation' for EAV attribute?

The options are disabled and I would like to activate them. The module I am using is Mirasvit
1 vote
0 answers
46 views

Magento 2.4: Change price filter text and range programmatically

I want to change the price filter text and range on the layered navigation from: To: Something like this: Under $30.00 $30.00 - $60.00 $60.00 - $90.00 $90.00 - $120.00 $120.00 and Above How can it ...
  • 330
1 vote
0 answers
20 views

How to unset layered navigation block if theres not filters inside layered navigation

How can I unset sidebar.main container if there's no layered navigation the layered search result page navigation if there's no filters catalogsearch_result_index.xml
8 votes
3 answers
1k views

Magento 2.4.5 layered navigation filter showing incorrect results

I've recently updated a non-production version of a website from 2.4.4 to 2.4.5. The site has a number of configurable products with options for colours etc. The simple products behind the ...
0 votes
1 answer
54 views

Magento 2 how to get product Ids in the Product listing page without pagination

I want to get the listed product's IDs in the product listing page without pagination. But the products will be listed with pagination. If it is filtered by layered navigation/search then I want that ...
1 vote
1 answer
102 views

How to remove particular filters from a specific category?

I want to remove the color and price filter only for the specific category in Magento 2.4.3-p1. I created a separate XML file (catalog_category_view_id_{category_id}.xml) and apply the below code. &...
  • 2,180
0 votes
1 answer
39 views

Rename Shop by and clear all text in left side Magento2

I want to change the text SHOP BY and clear all from left sidebar in list page
  • 475
0 votes
0 answers
35 views

How do I add a custom filter to layered navigation?

I need to add a new filter to this menu Filter items should be active categories that are not in the menu. I plan to get them this way: public function getCategoryCollection() { $...
0 votes
0 answers
31 views

Add Filter in Layered Navigation

i created an extra field in elasticsearch via an CustomDataProvider. Now i want to have those new fields from elasticsearch in the Layered Navigation. I found old examples for magento 1.x, but no new ...
  • 21
0 votes
0 answers
438 views

Product Filter Count Showing Wrong Count After Custom Product Collection - Magento Layered Navigation

I have applied custom filter on product collection to hide certain products from listing page. I have used below event for same <event name="catalog_product_collection_load_after"> ...
  • 3,573
0 votes
0 answers
22 views

Add Block To Layer Navigation As Filter Field

The layer navigation will display the filters when we config field use in Layer Navigation of product attribute as the document https://docs.magento.com/user-guide/catalog/navigation-layered-...
0 votes
0 answers
69 views

Magento 2: Product's Layered Navigation Filter DIsplay Type API

I am working on Rest API. I want a product filter type (checkbox, multiple selections,yes/no) so that mobile filters can be shown based on that. For example on website filters showing like this : How ...
  • 1,130
0 votes
0 answers
115 views

Adding Multi-Select Color Extensions in Layered Navigation of Magento 2

I need to add multi-select color extensions in my website , Can u suggest some extensions for this module in Magento 2 from this list weltpixel - https://www.weltpixel.com/improved-magento-2-layered-...
  • 1
0 votes
0 answers
20 views

Layered navigation click attribute filter ,Don't removed in the layernavigation magento 2.4.3

In default Magento, if we select any attribute from layered navigation to filter, the filtered products are shown but the selected attribute is removed. We need to display the selected attribute as ...
0 votes
0 answers
67 views

How to get child products from Layer Class Magento 2

14219 is the ID of the parent product. 14217, 14218 are the child product ids, I need to get from the Layer which products visibility is VISIBILITY_NOT_VISIBLE , can anyone help? Thanks class Layer ...
  • 738
0 votes
0 answers
40 views

Stock sources as filters layered navigation

I'm quite new to Magento2 so correct me if there is anything unclear or impossible to do. We have different stock sources (stock for Europe and for the UKs). I would like our customers to be able to ...
0 votes
1 answer
285 views

Add custom non-attribute filter when elastic search is enabled

I want to add custom non-attribute filter(data is coming from custom table which has product id as foreign key) when elastic search. I have already done for MySql engine but in case of Elastic search,...
  • 683
0 votes
1 answer
295 views

One category showing wrong sidebar layered navigation

I am using Porto theme, I upgraded Magento 2.2.4 to Magento 2.4.2, every thing working fine but there are 1 problem, all category page using app/design/frontend/Smartwave/porto/...
0 votes
0 answers
43 views

How we add a custom function to \Magento\LayeredNavigation\Block\Navigation

I overrode the \Magento\LayeredNavigation\Block\Navigation block and added a custom function, but while rendering the function in view.phtml, it shows a function not found error. Any once can help me. ...
0 votes
1 answer
781 views

How to get product collection total with pagination in magento 2

I have implemented pagination with limit & offset but when I am fetching the collection total after applying multiple filters then it's giving the wrong total count. $layer = $...
4 votes
1 answer
2k views

Custom condition for Elastic search collection in Magento 2

I am trying to add the custom condition for the product collection using the below plugin for elastic search. app/code/Vendor/Module/etc/frontend/di.xml <type name="Magento\Elasticsearch7\...
  • 175
1 vote
2 answers
2k views

How to solve this Exception #0 (Magento\Framework\Exception\StateException): The bucket doesn't exist

1 exception(s): Exception #0 (Magento\Framework\Exception\StateException): The bucket doesn't exist. Exception #0 (Magento\Framework\Exception\StateException): The bucket doesn't exist. #1 Magento\...
  • 23
0 votes
0 answers
389 views

How to fix layered navigation error in 3rd party module with category and price filters?

Running Magento 2.3.4 with Webkul Multivendor Marketplace Module and it is having compatibility issues with Mageplaza Ajax Layered navigation. The layered navigation and ajax filters doesn't seem to ...
  • 1
0 votes
1 answer
296 views

Magento 2: How to remove category layered navigation from search result

In Magento2.4.x how to hide categories from left side layered navigation on search result page only. Is there any setting/configuration or will have to do through code There is a configuration here ...
  • 141
0 votes
0 answers
98 views

Magento 2 shop by price is not showing on sub category pages

Magento 2.3.5-p2 shop by price is not showing on the subcategory page, it is showing on category pages
  • 1,185
0 votes
2 answers
1k views

Magento 2.4.1 Layered navigation with custom product collection

I want to override category product collection on the category product page in front-end. I want to show collection according to attribute set. After customize collection layered navigation product ...
  • 71
1 vote
0 answers
37 views

How does product count on layered navigation in Magento 2.4 is being rendered?

i'm using magento 2.4.1 and successfully overriding the product collection for layered navigation by overriding the getProductCollection method. The problem is the layered navigation sidebar showing ...
  • 99
1 vote
1 answer
102 views

How can i create custom filter with custom attribute in header panel in magento 2?

I create one product attribute which name "country" type drop-down. in that i add two country there US and CA now at front-end , front header show custom drop-down with that product option . ...
0 votes
0 answers
178 views

I want to add qty filter same as price filter in layered Navigation in Magento 2

In this i want to develop functionality in which qty filter is added and in that range is displayed in layered navigation as price filter. qty range as below: 1 - 50, 50 - 100, 100 - 150, ... so can ...
  • 535
0 votes
2 answers
295 views

Magento 2 How to change attribute filter position in layered navigation

I want to move the climate product attribute position from the bottom to the third position. Can you please help me out?
  • 384
0 votes
1 answer
682 views

Product collection override but filter not magento in Magento 2.4

I have override vendor/magento/module-catalog/Model/Layer.php for custom product collection but now the layer navigation and product count is working wrong, I checked for Magento\CatalogSearch\Model\...
  • 784
1 vote
2 answers
82 views

addAttributeToFilter for Multislect Attribute Update Query Magento 2

I have Multiselect product attribute and i want to filter product by that attribute. Currently i am using below code, $productCollection = $this->getLayer()->getProductCollection(); $...
1 vote
1 answer
715 views

Custom Product Collection not Getting Filtered by Layered Navigation in Magento 2.4.1

I am trying to create a page that show a list of products that have price which is greater than some specific amount and i also want to add Layered navigation for filter these product collection based ...
0 votes
1 answer
1k views

Magento 2.4 | Filters are no longer seen with Elasticsuite

I have updated Magento to version 2.4.2 and have also activated Elasticsuite as the default search engine. Elasticsuite installation went smoothly and the module is correctly installed. The search bar ...
  • 417
0 votes
1 answer
42 views

How to we move current applied filter state to center of the page just beside the sortby

In the category page layered navigation, I want to move the current applied filter state just beside the sort by or center of the page. Can anyone please help me out?
-3 votes
1 answer
810 views

Magento2: Can we add range slider on product attribute

[![enter image description here][1]][1] In current magento2 provide range slider on product attribute "price". I have requirement range slider on Case Diameter.
  • 25
1 vote
1 answer
627 views

After update Magento 2.3.5 to 2.4.2 on all category pages error: Exception #0 (RuntimeException): Catalog Layer has been already created. How fix?

After updating the version, I started getting on all category pages this error: Exception #0 (RuntimeException): Catalog Layer has been already created This is error in: vendor/magento/module-catalog/...
4 votes
3 answers
974 views

Magento 2.4: show variant images of configurable product based on filter

i have configurable product on listing page with swatches enabled . Configurable product has images swatches - Red , Green, Blue. Not when i applied Color - filter as Red still images on Listing page -...
0 votes
1 answer
41 views

No categories in the layered navigation

I stuck with a problem that some of the categories won't show in the layered navigation. An anchor is enabled, re-indexation and cache clearing made many times, changed the theme to default Luma. ...
  • 101
0 votes
1 answer
87 views

CATEGORY filter appearing two times

In Layered navigation There are two filters of same name appearing two times how can I remove the above one: We want to remove the first CATEGORY FILTER AND make the second to be displayed only?
1 vote
1 answer
2k views

Layered Navigation Filter Problem. Working in Magento 2.3.2 but not in Magento 2.4.1

I created this module about a year ago. Maybe because of elasticseach search engine or something now I am facing this error in Magento 2.4.1 main.CRITICAL: Error: Call to undefined method Magento\...
1 vote
1 answer
302 views

Show only filters in layered navigation for search results where all products have that filter populated

I am trying to implement this feature: the filters that are shown in the search results page are only visible if every products in that results page have the attribute linked with the filter populated....

1
2 3 4 5
17