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 6 of 6

Thread: How to Add own link to Category tree

  1. #1
    UNLGroup is offline Senior Member
    Join Date
    Dec 2007
    Posts
    144

    Default How to Add own link to Category tree

    Could someone explain how I might go about adding a custom built page node to the vertical category menu.
    I have a custom page that I'd like to add a link under one of my Categories for but I don't know the best way to do this.

    Any ideas?

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

    Default

    It's going to take some customization to link to that in the vertical menus, those are designed to just pull from entities. Depending on what's on your custom page, it might actually be easiest to just create a category with the name of whatever you wanted to name that link, and put the content of the custom page in the Description field. If you don't map any products to that category, it'll just be a content page.

  3. #3
    UNLGroup is offline Senior Member
    Join Date
    Dec 2007
    Posts
    144

    Default

    Thanks for the reply ( I might try that if I can't do it some other way)-

    Where's what I'm trying to do now (but I ran into a weird result)
    1) I added a quicksearch Category to the tree in the admin
    2)In the xml package I am trying to inject that link into the name but for some reason it's not letting me do this. When I hover the name on the page it still shows the link as being c-103-quick-search.aspx -- instead of SearchFilter.aspx, and when you click the name it just reloads the page.


    Code:
    <xsl:template match="SubCategory">
            <p align="left">
              •
              <!--<b>-->            
                <a style="font-size:10pt;">              
                  <xsl:attribute name="href">
                    <xsl:choose>
                      <xsl:when test="SEName='quick-search'">
                        <xsl:value-of select="SearchFilter.aspx" />
                      </xsl:when>
                      <xsl:when test="SEName!='quick-search'">
                        <xsl:value-of select="aspdnsf:CategoryLink(CategoryID,SEName,0)" />
                      </xsl:when>
                    </xsl:choose>
                  </xsl:attribute>
                  <xsl:value-of select="Name" disable-output-escaping="yes" />
                </a>
              <!--</b>-->
            </p>
          </xsl:template>

  4. #4
    Vortx is offline Junior Member
    Join Date
    Feb 2010
    Posts
    22

    Default

    At first glance it looks like you might need single quotes around search.aspx so that it is recognized as a string.
    You could probably also replace
    <xsl:value-of select="SearchFilter.aspx" />
    with
    <xsl:text>SearchFilter.aspx</xsl:text>

  5. #5
    Vortx is offline Junior Member
    Join Date
    Feb 2010
    Posts
    22

    Default

    And if the link is still to the category page then it looks like your match on sename is not working properly. Perhaps the case is wrong?

  6. #6
    UNLGroup is offline Senior Member
    Join Date
    Dec 2007
    Posts
    144

    Default

    It was the single quote.


    Thanks for the catch. That' got it working for the category on the page...

    Now all I need to do is figure out how/where to hack the vertical list link.


    Answer my own idea -->

    Vertical menu hack was done in the rev.category.xml.config file
    Last edited by UNLGroup; 04-20-2010 at 01:14 PM.