ASP.NET/.NET: Method to determine whether string is or contains HTML entity

Posted by ChrisIsTheBomb on Stack Overflow See other posts from Stack Overflow or by ChrisIsTheBomb
Published on 2010-05-20T17:06:06Z Indexed on 2010/05/20 17:10 UTC
Read the original article Hit count: 932

Filed under:
|
|
|
|

Is there a method anywhere in the .NET framework or System.Web that will tell me whether a string contains an HTML or is one?

Should I just Server.HtmlEncode(myString) and see if its length is longer than myString's length before encoding?

© Stack Overflow or respective owner

Related posts about ASP.NET

Related posts about .NET