Copied to clipboard

Flag this post as spam?

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


  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    May 14, 2010 @ 13:26
    Jeroen Breuer
    0

    Xslt custom error message

    Hello,

    Is it possible to create a custom error message if an error is throw in a XSLT file? Currently the user gets so see: Error parsing XSLT file: \xslt\HeaderImage.xslt. A custom message would be better. If this can't be done it should be in the next Umbraco version :).

    Jeroen

  • Matt Brailsford 4125 posts 22223 karma points MVP 9x c-trib
    May 14, 2010 @ 13:40
    Matt Brailsford
    0

    Doesn't look like it is possible without modifying the source right now as all exceptions get trapped, and the output is hard coded, so there isn't anything to hook into.

    If you wanted to do this, you'd need to modify the loadMacroXslt method in umbraco.macro.

    Matt

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    May 14, 2010 @ 13:51
    Jeroen Breuer
    0

    Hi Matt,

    For now I'll just add some extra if statements in my XSLT :). Still I think it would be a good thing to be able to create a custom error message. Same thing goes for user controls. A custom error would create a better user experience.

    Jeroen

  • Matt Brailsford 4125 posts 22223 karma points MVP 9x c-trib
    May 14, 2010 @ 13:52
    Matt Brailsford
    0

    If you REALLY wanted to display a message, I guess you could do some JS to find that string format and change it to a more friendly message?

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    May 14, 2010 @ 14:14
    Jeroen Breuer
    0

    You could do that, but it's not the way you want this to work. I've created a workitem for this. Please vote :).

    http://umbraco.codeplex.com/WorkItem/View.aspx?WorkItemId=27058

     

Please Sign in or register to post replies

Write your reply to:

Draft