Re: Products Pagination - Support Thread
Thanks so much for this great mod! I was actually looking for a mod that would let my customers choose how many products to display on a page, for search results, category listings, etc. But I didn't want to modify the individual product pages with any navigation that would let you go to different products within a category. It didn't seem to fit my website. I was able to accomplish this with your mod, by just not uploading changes to the following files:
includes/modules/mytemplate/product_prev_next.php
includes/templates/mytemplate/templates/tpl_products_next_previous.php
I was also able to modify the stylesheets to get the navigation to fit the color scheme of my website. I also changed the language files a little, so the navigation at the top would fit on one line, in many cases.
In case anyone wants to see how I used it, you can go to my website and do a search on a common term, like: vitamin.
http://www.earth-friendly.com
I do have one question.
Right now, for the number of items per page, I have: 12,24,48,96,300,600
In the case of searching for vitamin, it comes back with approximately 400 products. In the pulldown menu, it gives me these choices: 12,24,48,96,300. But, since there are 400 products, that means that I will always have at least 2 pages of products. I would prefer if it gave me a choice of 600 in this case, so I could choose to display them all in 1 page. Is there a place where I can change that? I'm guessing it would be a simple change, where something is off by 1.
Thanks again for a great mod! I really appreciate it. I love the way it looks on my site! :D
Re: Products Pagination - Support Thread
earth-friendly, I'll look at the code a bit later. I agree with your assessment, there's an incorrect comparison somewhere!
Re: Products Pagination - Support Thread
I've submitted v1.4.8 to the plugins area, correcting the issue that earth-friendly reported.
Re: Products Pagination - Support Thread
lat9, thanks very much! I don't see the new version there yet. Is it a simple change that I could make to my code? Would you mind telling me what the changes are? That would make it much easier for me, since I have already installed the previous version. Thanks so much for fixing this so quickly!
Re: Products Pagination - Support Thread
Sure, it's a relatively small change to the ppCountDropdown function of /includes/functions/extra_functions/products_pagination_functions.php
Code:
function ppCountDropdown ($numItems, $whichCount, $formSuffix) {
global $getoption_set, $get_option_variable, $cPath, $show_top_submit_button, $show_bottom_submit_button; // Used on product-listing/index page
$dropdown = '';
$countArray = explode(',', PRODUCTS_PAGINATION_COUNT_VALUES);
if (count($countArray) > 0) {
$pageArray = array();
for ($i=0, $n=sizeof($countArray), $done_all = false; $i<$n; $i++) {
if ($countArray[$i] == '*') {
if (!$done_all) {
$pageArray[] = array( 'id' => 'all', 'text' => PP_TEXT_ALL );
$done_all = true;
}
} elseif ($numItems > $countArray[$i]) {
$pageArray[] = array( 'id' => $countArray[$i], 'text' => $countArray[$i]);
} elseif (!$done_all) {
$pageArray[] = array ('id' => 'all', 'text' => PP_TEXT_ALL);
$done_all = true;
}
}
Re: Products Pagination - Support Thread
Thanks, that does the trick!
Re: Products Pagination - Support Thread
You're welcome! v1.4.8 is now available in the plugins area.
Re: Products Pagination - Support Thread
I've submitted v1.4.9 to the Plugins for approval. This version includes a previously-missed change for full Zen Cart v1.5.2/v1.5.3 compatibility.
Re: Products Pagination - Support Thread
Quote:
Originally Posted by
lat9
I've submitted v1.4.9 to the Plugins for approval. This version includes a previously-missed change for full Zen Cart v1.5.2/v1.5.3 compatibility.
... and it's now available! The plugin-reviewers are working overtime!
Re: Products Pagination - Support Thread
Thank you. I do have one problem I need assistance. I had to place an index.html on the root of the website. I had to adjust other zencart files to allow an index.html on the root where it should go to index.php
When I click on a page, like click page 3 of the pagination, it has index.html in the path
http://theplaypages.com/index.html?m...age=3&sort=20a
I need it to be
http://theplaypages.com/index.php?ma...age=3&sort=20a
I have removed the index.html on theplaypages.com for now because this is a live site and can't have the pagination broken.
Can you tell me which file to fix this in?
Why is it pointing to an index.html file anyway...
Thanks for your help in advance,
Karen