StringSort

Description

Sorts an input string.

Returns

Sorted string.

Category

Syntax

StringSort(string inputString)

History

ColdFusion (2021 release): Added in this release.

Parameters

Parameter

Description

inputString

(Required) The string to sort.

Example

<cfscript> 
    myCities="San Francisco";             
    writeOutput(StringSort(myCities)); 
 </cfscript>

Output

FSaaccinnors

Example 2

<cfscript> 
    cityArray = "LONDON";             
    sortedVal= StringSort(cityArray); 
    writeoutput(sortedVal) 
</cfscript>

Output

DLNNOO

 Adobe

Get help faster and easier

New user?