I have searched the forum and can not find any information on paginating the PLST page with numbers. I have category pages set up but the client wants to have the PLST paginate with numbers. I don"t want to use a Search module. I just simply want to paginate the PLST page with numbers. Does anyone know how to do this or is there a module that will allow me to do this? Thanks
Announcement
Collapse
No announcement yet.
Paginate the Product List page with numbers
Collapse
X
-
Re: Paginate the Product List page with numbers
I thought about putting this in the Emporium Plus Tool Kit but I keep coming back to the efficiency issue. Grabbing the total number of products would require an extra query to your database which could take a second or two if you have a lot of products. Also, it would not be accurate if you use availability groups or your products are hidden from view when the inventory is depleted. You have to know the total number before you can do the page numbering.Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
Facebook http://www.facebook.com/EmporiumPlus
Twitter http://twitter.com/emporiumplus
-
Re: Paginate the Product List page with numbers
No. The category typically has a couple dozen products. Whereas the whole store could have 100,000. It has to query the whole database rather than a one category subset.Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
Facebook http://www.facebook.com/EmporiumPlus
Twitter http://twitter.com/emporiumplus
Comment
-
Re: Paginate the Product List page with numbers
Because the module would need to know how many of the page numbers are there in total to display on the PLST page - and for that it would need to calculate how many products you have in the store and have access to. If it was just the total number of products it could be easy - just pull the number from the storekey database, but since some products can be unavailable to certain visitors (in availability groups, out of stock, etc), you can't use the "total number of products" and divide it by say 20 (if you do 20 products per page). So for this to work the module would need to go through ALL products in the store, see if you are allowed to view them (check all availability groups), see if each product is in stock, and then come up with total product count, and finally split that up to create page numbers. On a small store that may be ok, but on a store with 100,000 or more products it can take a few seconds, or longer (on a slow server).
Comment
-
Re: Paginate the Product List page with numbers
Originally posted by nburkha1 View PostYes, but the product list is already paginating using next and previous. Why can"t numbers be added instead or in addition to the previous and next? We are already conrolling how many products appear on the page.
Comment
-
Re: Paginate the Product List page with numbers
That is just telling it what is the next record (which is the next record in the database after the last one displayed). Not the first record on the next 50 or 500 pages. You have to know how many pages there are. For that you need to know the total count.Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
Facebook http://www.facebook.com/EmporiumPlus
Twitter http://twitter.com/emporiumplus
Comment
-
Re: Paginate the Product List page with numbers
I put the plstpages function in the Emporium Plus Tool Kit. It does check for the availability group and inventory status of the products so that the count is accurate for each visitor. As discussed above, you probably would not use this function in a MivaSQL store with 100,000 products. But a moderate MivaSQL store like this one http://www.pinemporium.com/mm5/merch...&Store_Code=PE or a much larger MySQL store should run with reasonable overhead.
The Tool Kit which has dozens of functions can be licensed from http://www.emporiumplus.com/go/wcw/PROD/1AA/1AA00223Last edited by wcw; 08-18-09, 01:43 PM.Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
Facebook http://www.facebook.com/EmporiumPlus
Twitter http://twitter.com/emporiumplus
Comment
Comment