How to create Alternate Featured Item section on home page?

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
ZLA
Commodore (COMO)
Commodore (COMO)
Posts: 496
Joined: Fri Mar 13, 2009 2:55 pm

How to create Alternate Featured Item section on home page?

Post by ZLA » Sun Jul 19, 2009 9:41 pm

We have two sections on our home page: Best Sellers and What's New. Best Sellers is based on Top Products while What's New is based on featured products. However, my client may want to pick and choose the exact products listed in the Best Sellers rather than basing it on sales.

Would the following approach work?
  • Assign the desired best seller products to a hidden (or private?) category. They would still be assigned to their normal public categories as well.
  • Replace the data source for the Best Sellers section with one that selects products from a specific category. (suggestions?)
Will the data source pull products from a hidden category?

Is there a better way to do this than what I envisioned?

Thanks in advance.

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: How to create Alternate Featured Item section on home page?

Post by mazhar » Mon Jul 20, 2009 3:10 am

If What's new section will contain exactly the same products as top products then what about using two instances of PopularProductsDialog with different captions.

Code: Select all

[[ConLib:PopularProductsDialog Orientation="HORIZONTAL" Columns="3"]]
[[ConLib:PopularProductsDialog Orientation="HORIZONTAL" Caption="What's new"  Columns="3"]]
Also here is a post about shuffling the top products
viewtopic.php?f=42&t=11593
Making use of this mod may show different products from top products for two different instances.

ZLA
Commodore (COMO)
Commodore (COMO)
Posts: 496
Joined: Fri Mar 13, 2009 2:55 pm

Re: How to create Alternate Featured Item section on home page?

Post by ZLA » Mon Jul 20, 2009 5:39 am

I'm sorry, I wasn't clear. The two sections will contain different products. One will be one set of featured products and the other will be a separate, different set of featured products. In essence, I want the behavior as if I had two separate featured flags, one for one set and the other for another set.

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: How to create Alternate Featured Item section on home page?

Post by mazhar » Mon Jul 20, 2009 6:32 am

In this scenario I think the solution you provided in your first post will workout.

ZLA
Commodore (COMO)
Commodore (COMO)
Posts: 496
Joined: Fri Mar 13, 2009 2:55 pm

Re: How to create Alternate Featured Item section on home page?

Post by ZLA » Mon Jul 20, 2009 7:26 am

When I look at the ProductDataSource class, it seems like there are million different methods I could use. Can you make a recommendation or give me hints as to what the main differences between the types of methods are? For example, I see methods for:
  • AdvancedSearch
  • FindProducts
  • LoadForCriteria
  • LoadForIds
  • NarrowSearch
Thanks.

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: How to create Alternate Featured Item section on home page?

Post by mazhar » Mon Jul 20, 2009 7:30 am

Make use of NarrowSearch like

Code: Select all

ProductDataSource.NarrowSearch(string.Empty, 23, 0, 0, 0);
where 23 represents your category id.

ZLA
Commodore (COMO)
Commodore (COMO)
Posts: 496
Joined: Fri Mar 13, 2009 2:55 pm

Re: How to create Alternate Featured Item section on home page?

Post by ZLA » Mon Jul 20, 2009 7:46 am

Wonderful! Thanks.

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: How to create Alternate Featured Item section on home page?

Post by jmestep » Mon Jul 20, 2009 7:55 am

I've done it a couple of different ways, but it was based on what you are suggesting- putting the products in a hidden category also. If you want the ones by just a particular category, you can have a hidden Featured Products sub category for each category.
I've adapted the GetRandomFeaturedProducts and used
// ProductList.DataSource = ProductDataSource.GetRandomFeaturedProducts(0, true,IncludeOutOfStockItems, this.Size);
//w2m jme 042809 pull from this category only
ProductList.DataSource= ProductDataSource.GetFeaturedProducts(_CategoryId, true, IncludeOutOfStockItems, _MaxItems, 0);

I've also done New Items that way where the merchant wanted to define the new items for each category, based on his choices, not a date filter.

if (node.Name.ToUpper() == "NEW ITEMS")
{
_NewItemsCategoryId = node.CatalogNodeId;
}
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

ZLA
Commodore (COMO)
Commodore (COMO)
Posts: 496
Joined: Fri Mar 13, 2009 2:55 pm

Re: How to create Alternate Featured Item section on home page?

Post by ZLA » Mon Jul 20, 2009 8:05 am

Thanks Judy.

Post Reply