Im trying to do at substring of my RTE content. I wnat the firs xxx characters. No problem. But seeing as the RTE content is html i want to strip the HTML. Got that too. but then i want to display html encoded chracters as normal chracters. that kinda works, but the substring routine cuts the encoded string and, leaves chunks of the encoding... im doing ti likes this
@Html.Raw(@Umbraco.StripHtml(@childPage.bodyText).ToString().Substring(0, 70))
ut in cases it leaves me something like this
Strygeinstrumenter er meget alsidige og bruges i alle genrer b&arin
How do i avoid this?
This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/49966-substring-html-encoded-string