The filter affects the entire section with the ID #content
-
I use a filter for product category pages. I have added the class?
.category-products
?to the section where both the filter and products are located. Additionally, I have inserted the following code snippet into the functions.php file:if( ! function_exists( 'yith_wcan_content_selector' ) ){ function yith_wcan_content_selector( $selector ){ $selector = '.category-products'; return $selector; } add_filter( 'yith_wcan_content_selector', 'yith_wcan_content_selector' ); }
The filter works well on categories with only one page of products. However, I encounter a problem with categories that have multiple product pages. After applying the attribute filter and switching to a different page, the filter affects the content of the entire section with the ID?
#content
, instead of just the?.category-products
?class. Is there a way to fix this issue? Please help me. Thank you very much.
- The topic ‘The filter affects the entire section with the ID #content’ is closed to new replies.