Home › Forums › WoodMart support forum › Products per page above 20 – Filtering too slow
Products per page above 20 – Filtering too slow
- This topic has 9 replies, 3 voices, and was last updated 5 years, 3 months ago by Artem Temos.
-
AuthorPosts
-
August 10, 2019 at 12:06 pm #137334
Stanley BlackParticipantHello,
When “Number of products per page” and “Products per page variations” are set to low number(10,12,15) everyting works fine. Filtering is working fast.
But when number of products per page is set above 20 or you select 24 for product per page variations filtering starts to work very slow.
Page refresh two times before filtering is done.Can you from your experience to advise me how to solve this problem?
Do I need better server permormances? or to modificate your theme and wooccommerce plugin?
Kind regards
August 10, 2019 at 11:32 pm #137413
Artem TemosKeymasterHello,
Try to do the following steps:
1. Be sure that you have deactivated all the external plugins while checking and don’t have child theme.
2. Update the theme and all the included plugins to the latest versions.
3. Disable swatches attribute to be displayed on the shop page in Theme Settings -> Shop -> Attribute swatches.
4. Go to Appearance -> Customize -> WooCommerce -> Product images, decrease images size for both single and catalog page and save to regenerate all thumbnails.
5. Keep plugins deactivated and send us the admin access so we can check it as well.
Kind Regards
August 18, 2019 at 7:23 pm #139045
Stanley BlackParticipantHello,
When theme is updated filtering starts to work faster.
It working without a problem when 40,50 products are set in “Number of products per page”.But I need more and I achieve that with disabling “AJAX functionality for filters widgets on shop” in Theme settings.
Now I need one more thing and my problem is resolved.
When filter is chose I want to page scroll to the filter section. Not to goes to the top of a page.
This is possible when “AJAX functionality for filters widgets on shop” is enabled
+ your custom codeadd_filter(
‘woodmart_ajax_scroll_offset’,
function(){
return 140;
},
10
);
How to achieve the same now when page is refreshing?Kind regards
August 19, 2019 at 6:40 am #139107
Eric WatsonParticipantHello,
We can increase the waiting time for a response from AJAX so that the page does not reload.
add_filter( 'woodmart_pjax_timeout', function(){ return 20000; } );
Kind Regards
XTemos StudioAugust 19, 2019 at 8:17 am #139139
Stanley BlackParticipantHello,
Thanks for your response.
This solutions also work but solution without Ajax is much more faster.
In future I will use CDN and Cloudflare and then refreshing page will be very fast.Is it possible to page scroll down to filter section on filter change?
Kind regards
August 19, 2019 at 8:38 am #139147
Artem TemosKeymasterSorry, but it works only when you use AJAX function for the shop page.
August 21, 2019 at 9:48 pm #139706
Stanley BlackParticipantHello,
Can you tell me which file is the parent of this file
themes\woodmart\woocommerce\content-product-base.php?which file is one step above?
I need that for custom coding.
Now my site has 1000 variable product and loading for product categories is above 15 sec.
Kind regards
August 22, 2019 at 6:36 am #139735
Artem TemosKeymasterHi,
It is included in the file
content-product.php
.Kind Regards
August 22, 2019 at 8:26 am #139761
Stanley BlackParticipantThank you!!!
Please can you provide me 3 more steps above?
1.?
2.?
3.?
4.content-product.php
5.content-product-base.phpKind regards
August 22, 2019 at 11:28 am #139762
Artem TemosKeymasterWe know that the general file is
archive-product.php
and all other steps above are related to WooCommerce and we don’t know exactly. -
AuthorPosts
- You must be logged in to create new topics. Login / Register