If you need to strip tags, you can you the method detailed below.
public static string StripTags(string str)
{
str = Regex.Replace(str, @"
]*>", " ", RegexOptions.IgnoreCase RegexOptions.Multiline);
str = Regex.Replace(str, @"<[^<>]*[>$]?", String.Empty, RegexOptions.IgnoreCase RegexOptions.Multiline);
str = str.Replace(" ", " ");
return HttpUtility.HtmlDecode(str.ToString());
}
Monday, July 2, 2007
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment