Copied to clipboard

Flag this post as spam?

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


  • Nik Wahlberg 639 posts 1237 karma points MVP
    Mar 23, 2009 @ 14:20
    Nik Wahlberg
    0

    XSLT not producing pages

    Hi all,

    I am finally getting back into the Umbraco thing. I have not had any projects (for Umbraco that is) until now. I am desperetly tring to get this XSLT working for a simple subnav....I can't believe I can't get this working?? Anyway, here it is:

    [code]







    [/code]

    This produces nothing but '
      ' in the source of the page. I have the following in the page structure currently:

      Content
      - Home
      - Some SubPage

      Shouldn't that produce those two pages?

      Sorry for the "stupid" question. Ohl, and I am using umbraco v 4.0.0 (Assembly version: 1.0.3317.32692).

      Thanks!

    • Dirk De Grave 4541 posts 6021 karma points MVP 3x admin c-trib
      Mar 23, 2009 @ 14:56
      Dirk De Grave
      0

      Nik,

      Your xslt will list child nodes of the 'Home' and 'Some SubPage' nodes (as those are the nodes at level = 1, which is what you've set as param)

      Either restructure the site so those two pages are listed as child page of a new 'Home' page or use GetXmlAll() to get all nodes, and iterate from there.

      Hope this helps.

      Regards,
      /Dirk

    • Nik Wahlberg 639 posts 1237 karma points MVP
      Mar 23, 2009 @ 15:09
      Nik Wahlberg
      0

      Hi Dirk, thanks for the quick response as always. I have actually tried both of those solutions and I still wind up with nothing. So, here's what the GetXmlAll looks like:

      [code]
      ]>

      version="1.0"
      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
      xmlns:msxml="urn:schemas-microsoft-com:xslt"
      xmlns:umbraco.library="urn:umbraco.library"
      exclude-result-prefixes="msxml umbraco.library">












      [/code]

      I was looking for a new release of 4.0 to see if there were any bugs or anything like that, but it looks like I have the latest (official) release too. Any other ideas? Hmmmm....

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

      Nik,

      Just tried your xslt on Warren's CWS2 site. It's a bit erronuous, not sure if this happens at your site as well. I'm using a nightly build from last week.

      [code][/code]

      does not save. Following snippet will:

      [code][/code]

      And using the latter, I was able to build complete nav (all descendants as specified) from the Home page... so it should work in your case as well.

      Regards,
      /Dirk


    • Nik Wahlberg 639 posts 1237 karma points MVP
      Mar 23, 2009 @ 15:54
      Nik Wahlberg
      0

      Huh.....I was not seeing the error upon saving, but I still changes it to variable instead of attribute. Thanks for picking up on that.

      I still don't get any pages. I think I will grab the latest build and see if that makes a difference. And, just to confirm, you have a similar structure to:

      Content
      - Home
      - Subpage
      - Blah

      Correct? (not that it should really matter given XmlAll...

      Thanks,
      Nik

    Please Sign in or register to post replies

    Write your reply to:

    Draft