Copied to clipboard

Flag this post as spam?

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


  • David Dupont 61 posts 115 karma points
    Aug 13, 2010 @ 16:52
    David Dupont
    0

    Custom XSLT Extension won't work on Umbraco 4.5

    Hello,

    Just a little topic to describe the problem I encounter on the migration of one website from the 4.0.3 to the 4.5, if it can avoid people some pain :D
    For that site we have written a lots of custom C# function that we use in our Xslt.
    That extension was binded using the xsltExtension.config file.

    <XsltExtensions>
      <!--
      <ext assembly="/bin/name-of-dll-without-dll-extension" type="Fully.Qualified.Name.Of.Type.Including.Namespace" alias="Prefix-to-use-in-xslt" />
      -->
      <ext assembly="/bin/XsltExtension" type="XsltExtension.GlobalUtils" alias="XsltExt" />
    </XsltExtensions>

    But after migration, xslt extensions won't work anymore.

    It seems that in the new version doesn't need the bin in the assembly attribute.
    Your Xslt file should be like this now.

    <XsltExtensions>
    <!--
    <ext assembly="name-of-dll-without-dll-extension" type="Fully.Qualified.Name.Of.Type.Including.Namespace" alias="Prefix-to-use-in-xslt" />
      -->
    <ext assembly="XsltExtension" type="XsltExtension.GlobalUtils" alias="XsltExt" />
    </XsltExtensions>

    Bye.

    David

     

  • Lee Kelleher 4020 posts 15802 karma points MVP 13x admin c-trib
    Aug 13, 2010 @ 17:31
    Lee Kelleher
    1

    Good point, well raised!

    The removal of the "/bin/" in the assembly value is actually noted in the upgrade to v4.5 guide. I'd highly recommend anyone upgrading from v4.0.x to v4.5 to read it first!

    As far as I am aware, it was removed because the assemblies for XSLT extensions would only be found in the /bin folder - so it was a little pointless prefixing "/bin/" to the DLL name.

    Cheers, Lee.

  • David Dupont 61 posts 115 karma points
    Aug 20, 2010 @ 19:55
    David Dupont
    0

    Hi Lee,

    Thanks for the tips.
    Sorry for the post but I'm used to search the forum and the wiki before asking.
    My mistakes. Hopes this will help some people doing the same search as mine.

    Cheers, David

Please Sign in or register to post replies

Write your reply to:

Draft