Community Add-Ons

Add file to this package
Top » InfoBoxes

Enhanced BestSeller box with admin
for osCommerce Online Merchant v2.2

Best Sellers- This contribution (V1.4) includes all the files and instructions that I used in my own installation to get things up and running in V2.2 MS2. I have incorporated other contibutions for this mod, and also don't take any responsibility if this doesnt work!
I you install this contrib your best seller box will:
-show thumb nails of the product.
-name of the product
-price of the product
-scroller for IE users else will display regular best_seller box
can be viewed at: www.theartoutlet.com

---
WHAT IS IT?
---
The purpose of this contribution is to replace the best seller Infobox that appears on the left or right column, to show selected products in the bestseller box, instead of actualy purchased products. The best sellers products can be chosen in the admin.

However, this mod could be improved by displaying the best sellers choosen for particular cPaths,like the original box does.

It's been written in such a way that the box will *not* show up if there are no bestsellers chosen.

Legend:  Download   Report

Expand All / Collapse All

Language Confusion problem MaNoLiA 6 Mar 2007  

fixed the problem with multilanguage shops:
demo: www.artesanias.de

search in boxes/besteller2.php

in line 31-36:
$bestseller_products_query = tep_db_query("select distinct p.products_id, p.products_image, pd.products_name, p.products_price, p.products_tax_class_id, s.status as specstat, s.specials_new_products_price from (" . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p) left join " . TABLE_SPECIALS . " s on (p.products_id = s.products_id) left join " . TABLE_BESTSELLER . " b on (p.products_id = b.products_id) and p.products_id = pd.products_id where p.products_status = '1' and b.status = '1' order by rand($mtm) DESC limit " . MAX_DISPLAY_BESTSELLER_PRODUCTS);
}
else {
$info_box_contents[] = array('align' => 'left', 'text' => sprintf(TABLE_HEADING_BESTSELLER_PRODUCTS_CATEGORY, $cat_name));
$bestseller_products_query = tep_db_query("select distinct p.products_id, p.products_image, pd.products_name, p.products_price, p.products_tax_class_id, s.status as specstat, s.specials_new_products_price from (" . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p) left join " . TABLE_SPECIALS . " s on (p.products_id = s.products_id) left join " . TABLE_BESTSELLER . " b on (p.products_id = b.products_id) and p.products_id = pd.products_id where p.products_status = '1' and b.status = '1' order by rand($mtm) DESC limit " . MAX_DISPLAY_BESTSELLER_PRODUCTS);
}

replace with:

$bestseller_products_query = tep_db_query("select distinct p.products_id, p.products_image, pd.products_name, p.products_price, p.products_tax_class_id, s.status as specstat, s.specials_new_products_price from (" . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p) left join " . TABLE_SPECIALS . " s on (p.products_id = s.products_id) left join " . TABLE_BESTSELLER . " b on (p.products_id = b.products_id) and p.products_id = pd.products_id where language_id = '" . (int)$languages_id . "' and p.products_status = '1' and b.status = '1' order by rand($mtm) DESC limit " . MAX_DISPLAY_BESTSELLER_PRODUCTS);
}
else {
$info_box_contents[] = array('align' => 'left', 'text' => sprintf(TABLE_HEADING_BESTSELLER_PRODUCTS_CATEGORY, $cat_name));
$bestseller_products_query = tep_db_query("select distinct p.products_id, p.products_image, pd.products_name, p.products_price, p.products_tax_class_id, s.status as specstat, s.specials_new_products_price from (" . TABLE_PRODUCTS_DESCRIPTION . " pd, " . TABLE_PRODUCTS . " p) left join " . TABLE_SPECIALS . " s on (p.products_id = s.products_id) left join " . TABLE_BESTSELLER . " b on (p.products_id = b.products_id) and p.products_id = pd.products_id where language_id = '" . (int)$languages_id . "' and p.products_status = '1' and b.status = '1' order by rand($mtm) DESC limit " . MAX_DISPLAY_BESTSELLER_PRODUCTS);
}

Enhanced Bestseller Box MySQL 5++ fix MaNoLiA 15 Jan 2007  
German translation and enable, disable box in the OSC Configuration schittli 24 Jul 2006  
Displaying thumbnail images in bestseller box AndyToogood 28 Nov 2005  
split_page_results.php Henrik J 19 Mar 2005  
Admin Link Does Not Work Johnny Kalsi 15 Jan 2005  
Enhanced BestSeller with admin for STS Fred Doherty 17 Dec 2004  
Install Instructions Fred Doherty 17 Dec 2004  
Bestseller Box with Admin Amitai Sasson 11 Jul 2004  
Readme.txt Schuyler 4 May 2004  
Fix for this great controb from Amitai Sasson Patrick Lemp 17 Mar 2004  
enhanced Best Seller Amitai Sasson 15 Mar 2004  
Enhanced BestSeller box with admin Amitai Sasson 15 Mar 2004