Fixes xss issue

This commit is contained in:
Shannon
2013-12-03 15:40:12 +11:00
parent e981776e6d
commit a7e32e97e3
7 changed files with 212 additions and 159 deletions

View File

@@ -842,7 +842,7 @@ namespace Umbraco.Core
/// This allows you to replace strings like & , etc.. with your replacement character before the automatic
/// reduction.
/// </remarks>
[UmbracoWillObsolete("This method should be removed. Use ToUrlSegment instead.")]
[Obsolete("This method should be removed. Use ToUrlSegment instead.")]
public static string ToUrlAlias(this string value, IDictionary<string, string> charReplacements, bool replaceDoubleDashes, bool stripNonAscii, bool urlEncode)
{
var helper = ShortStringHelper;
@@ -866,7 +866,7 @@ namespace Umbraco.Core
/// and <c>UmbracoSettings.RemoveDoubleDashesFromUrlReplacing</c>.</para>
/// <para>Other helpers may use different parameters.</para>
/// </remarks>
[UmbracoWillObsolete("This method should be removed. Use ToUrlSegment instead.")]
[Obsolete("This method should be removed. Use ToUrlSegment instead.")]
public static string FormatUrl(this string url)
{
var helper = ShortStringHelper;
@@ -933,7 +933,7 @@ namespace Umbraco.Core
/// <param name="removeSpaces">Indicates whether spaces should be removed. THIS PARAMETER IS IGNORED.</param>
/// <returns>The safe alias.</returns>
/// <remarks>CamelCase, and remove spaces, whatever the parameters.</remarks>
[UmbracoWillObsolete("This method should be removed. Use ToSafeAlias instead.")]
[Obsolete("This method should be removed. Use ToSafeAlias instead.")]
public static string ToUmbracoAlias(this string phrase, StringAliasCaseType caseType = StringAliasCaseType.CamelCase, bool removeSpaces = false)
{
var helper = ShortStringHelper;
@@ -978,7 +978,7 @@ namespace Umbraco.Core
/// <para>This is the legacy method, so we can't really change it, although it has issues (see unit tests).</para>
/// <para>It does more than "converting the case", and also remove spaces, etc.</para>
/// </remarks>
[UmbracoWillObsolete("This method should be removed. Use CleanString instead.")]
[Obsolete("This method should be removed. Use CleanString instead.")]
public static string ConvertCase(this string phrase, StringAliasCaseType cases)
{
var helper = ShortStringHelper;