Problem with pagination when using filters

  • Posts: 8
  • Thank you received: 1
  • Hikashop Business
1 month 10 hours ago #310135

-- url of the page with the problem -- : www.collectcamera.com/en-us/products/leica-equipment
-- HikaShop version -- : 4.2.1 build 1908091539
-- Joomla version -- : 3.9.11
-- PHP version -- : 7.2.20
-- Browser(s) name and version -- : all
-- Error-message(debug-mod must be tuned on) -- : links in pagination contain "tmpl=raw"

On our webshop we use extensive filtering to allow drill down to products.
From the menu one selects a main product category (menu: product layout=listing; prod.options: main category = set)
A set of filters is presented at the side for the drill down.

When the filter is used then regularly, but not always the links in the pagination contain the term "&tmpl=raw".
eg.: www.collectcamera.com/en-us/leica-equipm...=+&tmpl=raw&filter=1
I think the "&tmpl=raw" is is supposed to be removed by the ajax script. When the link is copied manually and this part is removed, then the proper page shows, clicking the link as is display the basic info, but without using any Joomla template.

A scan shows code for the removal in some views but not in all.
Compare:
listing.php = <form action="<?php echo str_replace('&tmpl=raw', '', hikashop_currentURL()); ?>"
listing_table = <form action="<?php echo hikashop_currentURL(); ?>"

Trying to fix this through overrides improved things slightly but it still happens. So probably there are some other places in the code where this is impacted.

Generally it does not show on short lists of products, the more items displayed the higher chances are of this occurring.

I feel that this may be a bug introduced with the new ajax filtering, we never experienced this before with v4.1.0

There are some overrides for the product display, but all of them disabled this still happens.

I hope this makes sense to you and you can help us fix it.

Cheers,
André

Please Log in or Create an account to join the conversation.

  • Posts: 66889
  • Thank you received: 9887
  • MODERATOR
4 weeks 2 days ago #310149

Hi,

Indeed, this comes from the AJAX filtering introduced in the 4.1.
We did the str_replaces for listing_div and forgot to add them to listing_table and listing_list.
Note that it's not only for the form tag but also for the getListFooter function call that this needs to be changed, and there are two pagination areas, at the beginning of the view and at the end as the pagination can be displayed on the top, the bottom or both.
I've added the changes there now and published a new build of the 4.2.1.
So you can download the install package of the latest version on our website and install it on yours and it should work much better now (of course if you have overrides on these files, you won't get the changes, so you'll have to port the changes to the overrides).
If you still notice issues with the AJAX filters, please let us know and describe the issues like you did here so that we can look into them.

The following user(s) said Thank You: multigeo

Please Log in or Create an account to join the conversation.

  • Posts: 8
  • Thank you received: 1
  • Hikashop Business
4 weeks 2 days ago #310154

A quick install in my test environment (without any overrides) seems to indicate this issue is now solved.
I will check and adapt the overrides later today and provide final confirmation after that.

Great job, really appreciate it !

Cheers,
André

Please Log in or Create an account to join the conversation.

  • Posts: 8
  • Thank you received: 1
  • Hikashop Business
4 weeks 2 days ago #310173

This is just to confirm that your fix seems to solve this issue.
Thanks again.
Cheers,
André

Please Log in or Create an account to join the conversation.

Time to create page: 0.058 seconds
Powered by Kunena Forum