I have an MVC3 app that uses a Telerik grid. I have a variable with html in it i want to display raw:
o.RawHtml = "This is a <br/> Test";
@(Html.Telerik().Grid(Model)
.Columns(columns =>
{
columns.Bound(o => o.RawHtml).ClientTemplate("<#= RawHtml #>").Title("Raw");
})
According to Telerik samples, this should work, but it doesnt. The output in a browser shows
“This is a < br/> Test”
and not the desired:
This is a
Test
Any ideas? Thanks
Have you tried setting the
Encodedproperty of the column tofalse? This page gives some information.By default, columns are html encoded.