static string HtmlEncode (string s) { if (String.IsNullOrEmpty (s)) return s; string res = HttpUtility.HtmlEncode (s); return res.Replace ("\r\n", "<br />"); }