0 ) { $xsell_query = $db->Execute("select distinct p.products_id, p.products_image, pd.products_name from " . TABLE_PRODUCTS_XSELL . " xp, " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where xp.products_id = '" . $_GET['products_id'] . "' and xp.xsell_id = p.products_id and p.products_id = pd.products_id and pd.language_id = '" . $_SESSION['languages_id'] . "' and p.products_status = 1 order by xp.sort_order asc limit " . MAX_DISPLAY_XSELL); $num_products_xsell = $xsell_query->RecordCount(); // don't display if less than the minimum amount set in Admin->Config->Minimum Values->Cross-Sell if ($num_products_xsell >= MIN_DISPLAY_XSELL && $num_products_xsell > 0) { ?> EOF) { $xsell_query->fields['products_name'] = zen_get_products_name($xsell_query->fields['products_id']); $list_box_contents[$row][$col] = array('params' => 'class="product-col col-lg-2 col-md-4 col-sm-4 col-xs-6"', 'text' => '
' . zen_image(DIR_WS_IMAGES . $xsell_query->fields['products_image'], $xsell_query->fields['products_name'], 200, 400) . '
' . $xsell_query->fields['products_name'] . '
' . (XSELL_DISPLAY_PRICE=='true'? '
'.zen_get_products_display_price($xsell_query->fields['products_id']):'') ); $col ++; if ($col > (SHOW_PRODUCT_INFO_COLUMNS_XSELL_PRODUCTS -1)) { $col = 0; $row ++; } $xsell_query->MoveNext(); } // store data into array for display later where desired: $xsell_data = $list_box_contents; } } ?>