Zen Cart Logo
Forums / General Questions / Best Sellers Table?

Best Sellers Table?

Locked

Views: 597

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
14 Mar 2010, 10:41 PM
#1
games4gamers avatar

games4gamers

New Zenner

Join Date:
Dec 2008
Posts:
55
Plugin Contributions:
0

Best Sellers Table?

Simple question, is there a separate table in the database that holds best sellers information? If so, which table is it. If not, where is this data stored?

Thanks.

14 Mar 2010, 11:08 PM
#2
coolcarpartsonline avatar

coolcarpartsonline

Totally Zenned

Join Date:
Feb 2008
Posts:
1,386
Plugin Contributions:
0

Re: Best Sellers Table?

I think it is automatically generated from order_products table. If you look into the code of the best seller box you would understand how it is generated.

15 Mar 2010, 12:24 AM
#3
games4gamers avatar

games4gamers

New Zenner

Join Date:
Dec 2008
Posts:
55
Plugin Contributions:
0

Re: Best Sellers Table?

CoolCarPartsOnline:

I think it is automatically generated from order_products table. If you look into the code of the best seller box you would understand how it is generated.

Ok thanks, I'll try that.

15 Mar 2010, 1:45 AM
#4
games4gamers avatar

games4gamers

New Zenner

Join Date:
Dec 2008
Posts:
55
Plugin Contributions:
0

Re: Best Sellers Table?

games4gamers:

Ok thanks, I'll try that.

Okay I looked and found this:

\includes\modules\sideboxes\best_sellers.php
Line 68: $bestsellers_list[$rows]['id'] = $best_sellers->fields['products_id'];
Line 69: $bestsellers_list[$rows]['name'] = $best_sellers->fields['products_name'];
\includes\templates\template_default\sideboxes\tpl_best_sellers.php (4 hits)
Line 14: for ($i=1; $i<=sizeof($bestsellers_list); $i++) {
Line 15: $content .= '<li><a href="' . zen_href_link(zen_get_info_page($bestsellers_list[$i]['id']), 'products_id=' . $bestsellers_list[$i]['id']) . '">' . zen_trunc_string($bestsellers_list[$i]['name'], BEST_SELLERS_TRUNCATE, BEST_SELLERS_TRUNCATE_MORE) . '</a></li>' . "\n";
Line 15: $content .= '<li><a href="' . zen_href_link(zen_get_info_page($bestsellers_list[$i]['id']), 'products_id=' . $bestsellers_list[$i]['id']) . '">' . zen_trunc_string($bestsellers_list[$i]['name'], BEST_SELLERS_TRUNCATE, BEST_SELLERS_TRUNCATE_MORE) . '</a></li>' . "\n";
Line 15: $content .= '<li><a href="' . zen_href_link(zen_get_info_page($bestsellers_list[$i]['id']), 'products_id=' . $bestsellers_list[$i]['id']) . '">' . zen_trunc_string($bestsellers_list[$i]['name'], BEST_SELLERS_TRUNCATE, BEST_SELLERS_TRUNCATE_MORE) . '</a></li>' . "\n";