At the moment on our home page we show all the categories with subcategories listed.
However we only want to show the first 5 subcategories for each parent category.
C#/VB.NET Code:
<xsl:choose>
<xsl:when test="count(/root/EntityHelpers/*[$scName]/descendant::Entity[ParentEntityID=$subCategoryId]) = 0">
<a href="{aspdnsf:EntityLink(EntityID, SEName, 'c', 0, '')}">List All Products</a>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="/root/EntityHelpers/*[$scName]/descendant::Entity[ParentEntityID=$subCategoryId]">
<a href="{aspdnsf:EntityLink(EntityID, SEName, 'c', 0, '')}">
<xsl:value-of select="Name" disable-output-escaping="yes" />
</a>
<br />
</xsl:for-each>
</xsl:otherwise>
</xsl:choose>
I could not see how to get it to work.
Anyone got any ideas? Thanks a lot in advance.