Copied to clipboard

Flag this post as spam?

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


  • Jon R. Humphrey 164 posts 455 karma points c-trib
    Mar 16, 2009 @ 18:54
    Jon R. Humphrey
    0

    [solved] create navigation list with children of only one specific parent

    If anyone could help an idiot! =p~

    I have two lists: dynamicNav & staticNav.
    Both need to show throughout the site.
    Currently I can only see both if I'm in a page held within staticNav; otherwise dyanmicNav is only shown.

    this is the staticNav.xslt, id=1148 is the parentNode.

    [quote]



      [/quote]

      I think it has something to do with this line:

      [color=red][/color]

      but I've tried

      [color=blue][/color]

      and

      [color=blue][/color]

      and

      [color=blue][/color]

      but to no luck other than to hide the list on all pages then!

      Thanks in advance if you have any ideas!

  • sun 403 posts 395 karma points
    Mar 17, 2009 @ 06:59
    sun
    0

  • Jon R. Humphrey 164 posts 455 karma points c-trib
    Mar 17, 2009 @ 11:01
    Jon R. Humphrey
    0

    Many thanks Sun,

    But that didn't work. I can still only see the staticNav if I'm in a page held by staticNav, not all the time which is what I need!

    But it's the thought that counts!

    J

  • sun 403 posts 395 karma points
    Mar 17, 2009 @ 11:09
    sun
    0

    Really my English is very poor, Maybe I don't know what you mean, Can you show me what you content structure is, just like:
    -a
    --a1
    --a2
    -b
    --b1
    --b2
    ......
    then show me what format is you want to output? like a,b or a,a1,a2,b,b1,b2?

  • Jon R. Humphrey 164 posts 455 karma points c-trib
    Mar 17, 2009 @ 17:46
    Jon R. Humphrey
    0

    The structure is as follows:
    -Home
    [dynamicNav]
    --Category < top level shown
    ---Client < only shown on separate breadcrumb and client listings
    ----Project < only shown on separate project listing
    -----Media/Image < displayed page

    ----Sub-Category < only shown on sub-menu
    -----Client< only shown on separate breadcrumb and client listings
    ------Project < only shown on separate project listing
    -------Media/Image < displayed page

    --External Link Pages < displayed pages

    [staticNav]
    --Information
    ---Section Pages < displayed pages

  • Jon R. Humphrey 164 posts 455 karma points c-trib
    Mar 18, 2009 @ 13:29
    Jon R. Humphrey
    0

    I thought maybe a small expansion on the actual static nav contents might help with figuring this out:

    The structure is:
    --Information
    ---About Us
    ---Clients
    ---News
    ---Awards
    ---Contact Us
    ---Client Login

    Now when I'm in any of the children of Information then I can see the staticNav:
    [quote]


    [/quote]

    but when I'm in any other section of the site (outlined in previous post) the entire staticNav content is gone and the XSLT returns:
    [quote]
      [/quote]

      I hope this makes things a bit clearer! So sorry for any confusion!

    • Jon R. Humphrey 164 posts 455 karma points c-trib
      Mar 18, 2009 @ 14:05
      Jon R. Humphrey
      0

      I've just tried something else and now I can see the staticNav anywhere BUT a child of Information!
      I changed this:
      [quote]

    • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
      Mar 18, 2009 @ 15:00
      Dirk De Grave
      0

      Hi,

      If node with id=1148 is parent node for which you'd like to list all child nodes, no matter where you're currently are, use

      [code][/code]

      Hope this helps.

      Regards,
      /Dirk

    • Jon R. Humphrey 164 posts 455 karma points c-trib
      Mar 18, 2009 @ 15:18
      Jon R. Humphrey
      0

      Thanks Dirk, but this generates the following error when saving:

      System.Xml.Xsl.XslTransformException: Extension object 'urn:umbraco.library' does not contain a matching 'GetXmlDocumentById' method that has 1 parameter(s).

      Am I missing something?

    • Jon R. Humphrey 164 posts 455 karma points c-trib
      Mar 18, 2009 @ 15:46
      Jon R. Humphrey
      100

      Dirk replied directly to me with the working solution:

      It should have been GetXmlNodeById() instead of GetXmlDocumentById()

      And all my troubles melt away!

    Please Sign in or register to post replies

    Write your reply to:

    Draft