View Single Post
  #1  
Old 01-05-2005, 10:08 AM
 
killjack47 killjack47 is offline
 

Newbie
  
Join Date: Dec 2004
Posts: 3
 

Default Help! Listing products under subcategories.

i'm working on a site in a custom design that i made. you can check it out here: www.cookiesfromars.com/index.php

BACKGROUND: i'm in a strange situation because there are actually only 14 products on the site - they are the quantities and sizes of cookies (ex: 1 dozen original size or 1/2 dozen small size). The cookie type is really more of an attribute although it will be determined by the category in which the customer finds the products.

that's all confusing, but hopefully it gives a little background to my question.

ISSUE: so i'm hacking my templates and i'm in the process of hacking my subcategories template so that when the user has selected a cookie type, they come to a page that lists all the products(quantities) in the 3 size categories along with their prices.

it easily lists the subcategories (the 3 sizes of that cookie category) but it doesn't easily list the products (quantity - ex: 1dozen) of that category. i'm trying something like:

Code:
{foreach from=$subcategories item=subcat} <TR> <TD align="left" class="Cat2Text">{ $subcat.category|escape }</TD> </TR> <TR> <TD> {if $subcat.product_count}{include file="customer/main/products.tpl" products=$subcat.categoryid} {/if} products={$subcat.categoryid}</TD> </TR> {/foreach}

that's not working at all for me. the products template gets called, but it doesn't see any products.

QUESTION: how do i get the products template to see the products in the subcategory i am in. in other words, what to i put after 'products=' to let the template know which products to list.

any help you can give would be greatly appreciated. thanks.
Reply With Quote