News:

Support the VirtueMart project and become a member

Main Menu

Pagination problems in VM 3.2.2

Started by ahmedfouad, October 13, 2018, 18:03:12 PM

Previous topic - Next topic

ahmedfouad


I'm having very persisting pagination problem I don't figure out how to solve it.
I searched the forum and Google for solutions for many days no luck
The problem is some times in the categories display page 2 appear first instead of page 1 any help will be appreciated Thanks.

GJC Web Design

at least live urls and urls to see the problem

switch off  SEF to test
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

#2
Thank you for your reply
Here it is
https://tajr.shop/ar/shop/gemstones

and here a photo to the problem
https://app.box.com/s/2shnvzg0uxgksrszc8isragzyv0z57fs

GJC Web Design

I don't see any pagination problems .. examples? urls? screenshots?
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

#4
Virtuemart category preview should display the first page if URL like this pressed
https://tajr.shop/ar/shop/gemstones
But instead some times I find the (second) page displayed instead when the same URL pressed
https://tajr.shop/ar/shop/gemstones

Screen shot
https://app.box.com/s/2shnvzg0uxgksrszc8isragzyv0z57fs

Here is a video about this problem because it's happen occasionally

https://youtu.be/HC68qqBAshA

The problem is in this case the second page cached in (Litespeed cache component) based on the URL witch is

https://tajr.shop/ar/shop/gemstones

And then distributed to all visitors,  I talked to the developers of litespeed cache about this and they reported that this problem happens with or without cache hits so it's not a litespeed cache problem.

Thank you for your time  :)


GJC Web Design

I tried these urls and I only ever see the 1st page

But if u sometimes see the second page then I can totally believe it is a caching issue ..
U can't cache everything ---  sometimes it is going to get it wrong
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

I tested my web site locally and done the following :

1- Disabled SEF URL of Joomla
2- Change the template
3- Uninstalled all extensions except the default Joomla extensions and Virtuemart
4- Updated Joomla and Virtuemart to the latest VER
4- Installed New Joomla and virtuemart installations in sub folder to compare settings (package downloaded from Virtuemart website containing Joomla and virtuemart)

With all this done my website acted locally as the following:

Step 1: when I press in to enter a category I see page one as normal and wen I navigate to page 2 every thing works fine
Step 2: I go to the home page of the store and returned to the same section at this case I don't see page one I see page 2
Step 3: In New Clean  installation (package downloaded from Virtuemart website containing Joomla and virtuemart)
Virtuemart acted differently as the same steps repeated no matter the page I was on when I return to the main page of section I see page one.
What could be the cause of that and how I can fix IT.
Thanks.

GJC Web Design

just tried this multiple times

QuoteStep 1: when I press in to enter a category I see page one as normal and wen I navigate to page 2 every thing works fine
Step 2: I go to the home page of the store and returned to the same section at this case I don't see page one I see page 2

I always land on page 1 with 12 products - not https://tajr.shop/en/shop/gemstones/rosary?start=12

must be your browser?
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

#8
Thank you for your time and support.
I clear the browser data before any testing.
I'm Currently still using Lightingspeed cache with cache live time (1) hour so if the pages already cached and generated (correctly and some times it's not) the problem will not appear.
If you please test the same steps mentioned earlier (I'm so sorry for your troubles :) ) in this demo it's identical to my site and the same result's I get in my local hosting happens in this demo also.


GJC Web Design

the example above does indeed load the 2nd page ( but without ?start=12) if i go

mens
mens page 2
home
mens // this is the mens url but with product 13-17

so can only be your caching .. is the site so slow/bad without it?
I rarely use any sort of caching on my sites -- I prefer to have a decent host/server/template/code that doesn't require caching to achieve acceptable results
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

Quote from: GJC Web Design on October 16, 2018, 19:18:44 PM
the example above does indeed load the 2nd page ( but without ?start=12) if i go

mens
mens page 2
home
mens // this is the mens url but with product 13-17



And this is exactly my problem if Litespeed cache the second page on main category URL without ?start=12.

This Demo site from Joomlart company website My guessing that they are using stranded Joomla cache and even without any caching in local hosting the same behavior happens.

Yes the site have good performance without caching but with cache the site ability to handle traffic triples so it's huge advantage.
I was wondering if there is any solution for that kind of behavior without discarding caching.
Note (Test in localhost without any caching):
If I deleted the site cookies (With the category main URL loading the second page) and refreshed the main category URL loads the first page normally.

GJC Web Design

enable the Joomla debug

then at the bottom you can study the session info .. clearing the cookies just disconnects the session .. nothing will be stored in a cookie but something may be seen in the session that gives you some clue
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

ahmedfouad

Thank you very much for your Time I Will give it a try.

0racle

Open /components/com_virtuemart/router.php file and replace the code in line 140:


} else if ( $start>0 ) {


with the code:


} else if ( $start>=0 ) {