Copied to clipboard

Flag this post as spam?

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


  • Laurence Gillian 600 posts 1219 karma points
    Jul 01, 2013 @ 16:51
    Laurence Gillian
    0

    6.1.2 - XSLT Includes, File not found. (Sub Folders)

    Just run into this issue with Umbraco 6.1.2 where it returns a 'System.IO.DirectoryNotFoundException: Could not find a part of the path' error. When referencing a file relative to a file in the same sub directory.

    In 4.x.x, you could reference an include using the following syntax:

    <xsl:include href="../templates/_Article.xslt" />
    Which would translate to: [xslt]/templates/Article.xslt (e.g. get me something in the XSLT folder)

    In 6.1.2, the error says C:\LocalDev\vdb.1020.beth\VS.NET\beth.portfolio.Web\templates\_Gallery.xslt

    Noticed the XSLT folder has been dropped.

    To work now includes need to be written as:

    <xsl:include href="../xslt/templates/_Article.xslt"/>
    or
    <xsl:include href="templates/_Article.xslt"/>
    <xsl:include href="helpers/_MultiPicker.xslt"/> 

    -

    So it looks like when the XSLT processor handles an include, it treats all files as if they are inside "/XSLT", and not a sub folder? Essentially flattening out the file system.

    -

    Is that the desired behavior or is that a bug? It seems a bit explict to me? 

    Laurence

     

  • Laurence Gillian 600 posts 1219 karma points
    Jul 01, 2013 @ 17:16
    Laurence Gillian
    0

    Scrub that, it works as it did before...

    It's just the way the errors get reports in the Visulizer which is a bit odd! Ignore the paths in the Visulizer, it's wrong!

    the old ../ way works :) Problem solved. Laux 

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies