| 
 | ||||||||||
|  | Shopping cart software Solutions for online shops and malls | |||||||||
|  |  |  | ||||||||
| X-Cart Home |  FAQ |  Forum rules |  Calendar |  User manuals |  Login | 
|  | 
| Subcategory Count? | |||
|  |  | ||
|  | Thread Tools | Search this Thread | 
| 
			 
			#1  
			
			
			
			
		 | |||||||
| 
 | |||||||
|  Subcategory Count? X-Cart version 4.3 I am displaying the subcategories only for the currently active parent category using the following code. I can not seem to find how to hide the info if nothing exists. What is happening is the unordered list is creating a space even if the list is empty. I want it to not create the list HTML if there are no sub cats of the parent cat. I am also leaving in this code I am using what I *thought* should work but has failed me. (see red code) Code: 
 | |||||||
| 
			 
			#2  
			
			
			
			
		 | |||||||||
| 
 | |||||||||
|  Re: Subcategory Count? {if $subcategory.subcategory_count gt 0} There is no $subcategory array in this code. replace it with $c. The correct code should be {if $c.subcategory_count gt 0}..... Also check in debug window that there is such thing as "subcategory count" 
				__________________ Steve Stoyanov CFLSystems.com Web Development | |||||||||
| 
			 
			#3  
			
			
			
			
		 | |||||||
| 
 | |||||||
|  Re: Subcategory Count? Thanks Steve! That worked perfectly. I still have not figured out the debug window though... 
				__________________ ~Dani For version & mods installed, see post.   | |||||||
| 
			 
			#4  
			
			
			
			
		 | |||||||
| 
 | |||||||
|  Re: Subcategory Count? I found one problem. When I click into a subcategory then go to a product whose main category is the sub-category, the sub-categories disappear. Here are breadcrumbs: Code: 
 The side navigation only shows the list of parent categories. 
				__________________ ~Dani For version & mods installed, see post.   | |||||||
|  | |||
| 
X-Cart forums © 2001-2020
 | |||