Search code examples
sitefinity

Sitefinity Text line breaks


In my model I have text with tag where I would like to replace it with a html
tag. I did search and show that using Html.Encode may work but that didnt work.

is there another way to do this in the cshtml file?

@Html.Encode(Model.Desceiption).Replace("<cr>", "<br>") 

Solution

  • I think you want

    @Html.Raw(...)