C# Class Felinesoft.UmbracoCodeFirst.Extensions.StringHelperExtensions

Convenience methods used when formatting and transforming Umbraco values to valid C# member names.
显示文件 Open project: DanMannMann/UmbracoCodeFirst

Public Methods

Method Description
HyphenToUnderscore ( string input ) : string

Replace hyphen ('-') with underscore ('_')

ParseUrl ( string input, bool toLowerCase = true, bool allowCommas = false ) : string

Function to parse an URL to a better format

Method Details

HyphenToUnderscore() public static method

Replace hyphen ('-') with underscore ('_')
public static HyphenToUnderscore ( string input ) : string
input string
return string

ParseUrl() public static method

Function to parse an URL to a better format
public static ParseUrl ( string input, bool toLowerCase = true, bool allowCommas = false ) : string
input string The URL that needs to be parsed
toLowerCase bool True to convert the URL to lower case
allowCommas bool True to allow commas in the output
return string