Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Dane Garcia 6 posts 56 karma points
    Jan 22, 2013 @ 22:17
    Dane Garcia
    0

    Display all sub nodes for homepage on every page

    I am currently using the site map template to generate the lists/sublists for my drop down navigation. The default xslt code only displays for "$currentPage", is there a variable to use for the root page like "$root"?

  • Charles Afford 1163 posts 1709 karma points
    Jan 22, 2013 @ 22:57
    Charles Afford
    0

    hi, could you explain a bit more about what you are trying to do here?  $currentPage is the page in context  $currentPage/child::* is any children of the currentPage.  $currentPage/child::[inserttemplatenamehere] is any child of currentPage of a particular template and $currentPage/descendant-or-self::* or ::[inserttemplatenamehere] is the currentPage or any of its children regardless of depth.  Hope this helps.  Charles :)

  • Charles Afford 1163 posts 1709 karma points
    Jan 22, 2013 @ 22:58
    Charles Afford
    0
  • Dane Garcia 6 posts 56 karma points
    Jan 24, 2013 @ 13:19
    Dane Garcia
    0

    I actually figured it out, I didn't realize that $currentPage/acestor-or-self::*[@level = 1] will always pull up the sites home page?

  • Charles Afford 1163 posts 1709 karma points
    Jan 25, 2013 @ 14:31
    Charles Afford
    0

    It depends on where your home page is, but level 1 is the top node (of which you could have mutilpul)  glad you worked it out :)

Please Sign in or register to post replies

Write your reply to:

Draft