Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Listing Number of Items in a Category on the Menu

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 06-07-2006, 04:53 PM
 
MCM MCM is offline
 

Senior Member
  
Join Date: Dec 2005
Posts: 114
 

Default Listing Number of Items in a Category on the Menu

Hi,

Right now, my menu shows the number of products in any given category after the category name with the following code:

Code:
[*]<A href="home.php?cat={$categories[cat_num].categoryid}" class="VertMenuItems">{$categories[cat_num].category} ({$categories[cat_num].product_count|default:0})

The problem is that when products are out of stock, they don't appear in the listing, but they remain in the database. Therefore, I might have 15 items in a category, but only 10 in stock. Someone will see "Category (15)" on the menu, but only 10 products appear when they open the category page.

Do you know how this can be fixed? I don't want to delete items, because I've heard this messes up people's invoices (as well as our records).

Thanks!
__________________
Version 4.0.17/4.0.18
Reply With Quote
  #2  
Old 06-29-2006, 11:21 PM
 
MCM MCM is offline
 

Senior Member
  
Join Date: Dec 2005
Posts: 114
 

Default

Does anyone have any advice on this? In setting up a new cart, I just ran into the problem again.

In this case, one of my test items (quantity: 1) was purchased. Now, of the original 3 items in its category, two are available. However, the category list still shows 3 available. I'm really at a loss for how to calculate this another way to avoid the glitch.

Thanks,

Jeremy
__________________
Version 4.0.17/4.0.18
Reply With Quote
  #3  
Old 07-20-2006, 07:11 AM
 
equinetackstore equinetackstore is offline
 

Advanced Member
  
Join Date: May 2006
Posts: 47
 

Default

Hi:

I'd be interested in knowing the fix to this as well for version 4.018.

If anyone has any ideas, please let us know.

Thanks in advance!
__________________
Nanci
Version 4.018 (stable)
Template by Dana7
Grouped Categories
X-RMA
X-Magnifier
Remember Me
Buyers also Bought
X-AOM
Pleasant Payment Details
Printable Catalog
X-SpecialOffers
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 02:37 PM.

   

 
X-Cart forums © 2001-2020