Remove html tags from input
This is a handy little method that helps you keep your input free from html code.
private string StripAnyTags(string s)
{
if (s != null)
{
return Regex.Replace(s, @"(<[a-z]+[^>]*>)|(</[a-z\d]+>)", "",
RegexOptions.IgnoreCase | RegexOptions.ExplicitCapture);
}
return string.Empty;
}