Umbraco Razor Add Line Breaks to Textbox multiple


@if (@Model.address != "")
{

var output = (umbraco.library.ReplaceLineBreaks(@Model.address));
<p>@Html.Raw(@output)</p>
}

Comments

  1. Brilliantly simple! Thanks mate.

    ReplyDelete
  2. Thanks for putting this out there. This saved me at least a half hour of figuring why it was being stripped in the first place.

    ReplyDelete

Post a Comment

Popular posts from this blog

Umbraco Razor Sort Nodes Ascending or Descending

Umbraco Razor get Querystring

Create a .NET Contact Form that Gets the Last Url Visited in C# Can also be Used in Umbraco