Important Notice from AspDotNetStorefront
It is with dismay that we report that we have been forced, through the action of hackers, to shut off write-access to this forum. We are keen to leave the wealth of material available to you for research. We have opened a new forum from which our community of users can seek help, support and advice from us and from each other. To post a new question to our community, please visit: http://forums.vortx.com
Results 1 to 5 of 5

Thread: Showing SubCat and SubMan Descriptions

  1. #1
    dnbriden is offline Junior Member
    Join Date
    Sep 2009
    Posts
    18

    Default Showing SubCat and SubMan Descriptions

    Our current site (using a different shopping cart) shows a description next to each subcategory (see attachment). We are trying to use this same format with sub categories and sub manufacturers in our new ASPDNF site. All of the base XML packages I have tried only display a photo and title, but no description. Has anyone done this that could point me in the right direction? Is this an XML mod or is there a setting I need to change?
    Attached Images Attached Images  

  2. #2
    AspDotNetStorefront Staff - Scott's Avatar
    AspDotNetStorefront Staff - Scott is offline Administrator
    Join Date
    Mar 2007
    Location
    Ashland, OR
    Posts
    2,390

    Default

    That would be an XML mod, but a pretty simple one. Something like just adding this bolded line to the entity.simpleproductlist.xml.config XmlPackage (or whatever package you're using):

    Code:
                <xsl:template name="SubCatCell">
                    <xsl:param name="scName"></xsl:param>
                    <xsl:param name="pSEAltText" select="aspdnsf:GetMLValue(SEAltText)"></xsl:param>
                    <xsl:param name="AltText">
                        <xsl:choose>
                            <xsl:when test="$pSEAltText=''"><xsl:value-of select="$scName" /></xsl:when>
                            <xsl:otherwise><xsl:value-of select="$pSEAltText" /></xsl:otherwise>
                        </xsl:choose>
                    </xsl:param>
    
    
                    <xsl:param name="URL"><xsl:value-of select="aspdnsf:EntityLink(EntityID, SEName, $EntityName, 0, '')" /></xsl:param>
    
                    <td align="center">
                        <a href="{$URL}">
                            <xsl:value-of select="aspdnsf:LookupEntityImage(EntityID, $EntityName, 'icon', 0, $AltText)" disable-output-escaping="yes" />
                        </a>
                        <br/>
                        <a href="{$URL}">
                            <xsl:value-of select="$scName" disable-output-escaping="yes"/>
                        </a>
    			<br/>
    			<xsl:value-of select="aspdnsf:GetMLValue(Description)" disable-output-escaping="yes" />
                    </td>
    
                </xsl:template>
    You can add whatever other breaks/formatting you want too of course

  3. #3
    dnbriden is offline Junior Member
    Join Date
    Sep 2009
    Posts
    18

    Default

    Scott, this worked brilliantly. I added a table and some formatting into the XSL to nail down my page layout. I also found that I can use the 'Summary' field for a short description on the category page and then use the 'Description' field for my longer data. This works for sub-manufacturers as well. Thank you for your help.

  4. #4
    Richnyc30 is offline Senior Member
    Join Date
    Mar 2009
    Posts
    340

    Default Could you use the Summary field

    Although the bold line was not bold on my computer, it looked like you were calling the Descripion field. Hopefully it is only a name change that will bring up the Summary.

  5. #5
    Richnyc30 is offline Senior Member
    Join Date
    Mar 2009
    Posts
    340

    Default Easy to change to Summary field

    In the search results page, just change the word "Description" to "Summary", don't even nedd to change variable names, and the Summary data will appear instead of Description.
    No need to change SQL calls or anything else. In fact, the summary data should be the default as too much room on the search results pages is devoured by long descriptions, which are really necessary for most products.