WikiFunctions.Tools.RemoveSyntax C# (CSharp) Method

RemoveSyntax() public static method

Removes underscores and wiki syntax from links
public static RemoveSyntax ( string text ) : string
text string
return string
        public static string RemoveSyntax(string text)
        {
            if (string.IsNullOrEmpty(text))
                return text;

            text = text.Trim();

            if (string.IsNullOrEmpty(text))
                return text;

            if (text[0] == '#' || text[0] == '*')
                text = text.Substring(1);

            text = text.Replace("_", " ").Trim();
            text = text.Trim('[', ']');
            text = text.Replace(@"&", @"&");
            text = text.Replace(@""", @"""");
            text = text.Replace(@"�", "");

            return text.TrimStart(':');
        }
Tools