How to render HTML string in ASP.NET MVC?

后端 未结 1 995
难免孤独
难免孤独 2020-12-04 23:44

On my main page, I have the code @{Html.RenderPartial(\"_Partial1.cshtml\");}, and on my Partial, I have an HTML string:

@{ 
    // The string i         


        
相关标签:
1条回答
  • 2020-12-04 23:49

    You can use the Html.Raw() method for that.

    0 讨论(0)
提交回复
热议问题