backports some updates made in the dist load balancing branch that allows for examine path storage by machinename and appdomainappid

This commit is contained in:
Shannon
2015-02-13 14:50:16 +11:00
parent 15c36a63d3
commit 0600d5c463
3 changed files with 29 additions and 12 deletions

View File

@@ -101,6 +101,17 @@ namespace Umbraco.Core
}
}
internal static string ReplaceNonAlphanumericChars(this string input, string replacement)
{
//any character that is not alphanumeric, convert to a hyphen
var mName = input;
foreach (var c in mName.ToCharArray().Where(c => !char.IsLetterOrDigit(c)))
{
mName = mName.Replace(c.ToString(CultureInfo.InvariantCulture), replacement);
}
return mName;
}
internal static string ReplaceNonAlphanumericChars(this string input, char replacement)
{
//any character that is not alphanumeric, convert to a hyphen