You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 11, 2018. It is now read-only.
That was a change in #53 and released in 3.3.5.3 to match up behavior of adding content to an element with what the native Razor controls do. I.e., it'll now automatically HTML escape plain strings. The simple way around this is to use new HtmlString():
.SetControlLabel(new HtmlString("SQL Server <span class='badge badge-primary'>Recommended</span>"))
Not sure if you noticed but your above solution does not work for me. The string is still rendered as plain text (without the Bootstrap badge visible). That's with me adding .ToHtmlString() to the end of your solution above.
This is now resolved in the develop branch and will (hopefully) go out with a release later this week. You'll be able to use the new HtmlString() syntax above for SetControlLabel() as well as many other extensions.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
If I use the below as the parameter for the function it is rendered on the page as below making it difficult to style the items in the label.
.SetControlLabel("SQL Server <span class='badge badge-primary'>Recommended</span>")
The text was updated successfully, but these errors were encountered: