Copied to clipboard

Flag this post as spam?

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

  • Jukka-Pekka Keisala 90 posts 226 karma points
    Jul 19, 2022 @ 07:48
    Jukka-Pekka Keisala

    StripHtml and Truncate in v10

    How do I strip and truncate html in v10? Is there a helper built in Umbraco for this?

  • Corné Hoskam 80 posts 587 karma points MVP 3x c-trib
    Jul 19, 2022 @ 09:36
    Corné Hoskam

    Hi Jukka-Pekka,

    The Umbraco.Extensions.StringExtensions class has a .StripHtml() extension method you can call on any string. This will return the string without any HTML tags in it!

    Hope this helped,


Please Sign in or register to post replies

Write your reply to: