Page 1 of 1

Split Page Results

Posted: Sat Dec 31, 2022 8:32 pm
by tessthepup
Just wondering if there are little snippets or pearls that would hide the split page results if there is only one page of products?

As there are several places that use split page results not just the product listing it would be good to change all in one go if possible.

Re: Split Page Results

Posted: Sun Jan 01, 2023 12:08 am
by ecartz
It's a template. Override it and change two lines:

https://github.com/CE-PhoenixCart/Phoen ... ng.php#L23
https://github.com/CE-PhoenixCart/Phoen ... ng.php#L92

Change > 0 to be > $num_list, e.g.

Code: Select all

    if ( ($listing_split->number_of_rows > $num_list) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {
Note: this is assuming the core behavior. If this doesn't work, you may want to check if your customizations have changed something.

Re: Split Page Results

Posted: Sun Jan 01, 2023 10:48 am
by tessthepup
ecartz wrote: Sun Jan 01, 2023 12:08 am It's a template. Override it and change two lines:

https://github.com/CE-PhoenixCart/Phoen ... ng.php#L23
https://github.com/CE-PhoenixCart/Phoen ... ng.php#L92

Change > 0 to be > $num_list, e.g.

Code: Select all

    if ( ($listing_split->number_of_rows > $num_list) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) {
Note: this is assuming the core behavior. If this doesn't work, you may want to check if your customizations have changed something.
@ecartz

Thanks line 92 did the trick as I only display the page results at the bottom of the page.