Documentation > CMS Template API Library > Util > GetExtension(String)
GetExtension
Takes a filename and returns its extension. Wil return empty if no extension is found. Ex: GetExtension("input.aspx") will return "aspx"
public System.String GetExtension(String)
Returns
The extension without the ".", or an empty string.
Parameters
Name | Description | Type |
---|---|---|
filename | File name to extract the extension from. | System.String |