Originally Posted by
twitchtoo
This error points at includes/classes/split_page_results.php
line 74 - 78
$count_query = "select count(" . $count_string . ") as total " . substr($this->countQuery, $pos_from, ($pos_to - $pos_from));
if ($debug) {
echo 'count_query=' . $count_query . '<br /><br />';
}
$count = $db->Execute($count_query);
Clicking that button pulls these files:
includes/templates/YOUR_TEMPLATE/templates/tpl_products_all_default.php
line 63
<div id="allProductsListingBottomLinks" class="navSplitPagesLinks forward"><?php echo TEXT_RESULT_PAGE . ' ' . $products_all_split->display_links(MAX_DISPLAY_PAGE_LINKS, zen_get_all_get_params(array('page', 'info', 'x', 'y', 'main_page'))); ?></div>
includes/templates/YOUR_TEMPLATE/templates/tpl_modules_products_all_listing.php
line 22 - 23 if ($products_all_split->number_of_rows > 0) {
$products_all = $db->Execute($products_all_split->sql_query);includes/modules/pages/products_all/header_php.php
line 66
if ( (($how_many > 0 and $show_submit == true and $products_all_split->number_of_rows > 0) and (PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART == 1 or PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART == 3)) ) {
What are the chances your template changed any of these files or what happens when you switch back to the classic template with the products_all turned on?
I have the same problem when “All products or Special products” are clicked
I am using Winchester responsive template, Zen cart v1.5.5d, Ceon Advanced Shipper 5.0.2 and Sitemap XML
Lines 74-78 in includes/classes/split_page_results.php show:
Code:
$count_query = "select count(" . $count_string . ") as total " . substr($this->countQuery, $pos_from, ($pos_to - $pos_from));
if ($debug) {
echo 'count_query=' . $count_query . '<br /><br />';
}
$count = $db->Execute($count_query);
includes/templates/YOUR_TEMPLATE/templates/tpl_products_all_default.php shows:
Code:
<div class="centerColumn" id="allProductsDefault">
<h1 id="allProductsDefaultHeading"><?php echo HEADING_TITLE; ?></h1>
<?php
require($template->get_template_dir('/tpl_modules_listing_display_order.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_listing_display_order.php');
require($template->get_template_dir('tpl_modules_product_listing.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_modules_product_listing.php');
?>
</div>
lines 22-23 in includes/templates/YOUR_TEMPLATE/templates/tpl_modules_products_all_listing.php shows:
Code:
if ($products_all_split->number_of_rows > 0) {
$products_all = $db->Execute($products_all_split->sql_query);
includes/modules/pages/products_all/header_php.php
line 66-74 shows:
if ( (($how_many > 0 and $show_submit == true and $products_all_split->number_of_rows > 0) and (PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART == 1 or PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART == 3)) ) {
$show_top_submit_button = true;
} else {
$show_top_submit_button = false;
}
if ( (($how_many > 0 and $show_submit == true and $products_all_split->number_of_rows > 0) and (PRODUCT_ALL_LISTING_MULTIPLE_ADD_TO_CART >= 2)) ) {
$show_bottom_submit_button = true;
} else {
$show_bottom_submit_button = false;
}
If I change to the default template, the products display fine without a myDEBUG error.
Bookmarks