Whatever message this page gives is out now! Go check it out!
GetToken(string, index [, delimiters ]) |
Parameter | Description |
string | A string or a variable that contains one. String in which to search. |
index | Positive integer or a variable that contains one. The position of a token. |
delimiters | A string or a variable that contains one. A delimited list of delimiters. Elements may consist of multiple characters.Default list of delimiters: space character, tab character, newline character; or their codes: "chr(32)", "chr(9)", chr(10). Default list delimiter: comma character. |
<cfoutput>#GetToken("red,blue:;red,black,tan:;red,pink,brown:;red,three", 2, ":;")#</cfoutput><cfset mystring = "four,"
& #chr(32)# & #chr(9)# & #chr(10)#
& ",five, nine,zero:;"
& #chr(10)#
& "nine,ten:, eleven:;twelve:;thirteen,"
& #chr(32)# & #chr(9)# & #chr(10)#
& ",four">
<cfoutput>
#HTMLCodeFormat(mystring)#<br><br>
</cfoutput>four, ,five, nine,zero:; nine,ten:, eleven:;twelve:;thirteen, ,four |
<br> <cfoutput> GetToken(mystring, 3) is : #GetToken(mystring, 3)# </cfoutput><br> |
GetToken(mystring, 3) is : nine,zero:; |
<cfset mystring2 = "four," &#chr(9)# & #chr(10)# & ",five,nine,zero:;" & #chr(10)# & "nine,ten:,eleven:;twelve:;thirteen," & #chr(9)# & #chr(10)# & ",four"> <cfoutput> #HTMLCodeFormat(mystring2)#<br> </cfoutput> |
four, ,five,nine,zero:; nine,ten:,eleven:;twelve:;thirteen, ,four |
<cfoutput> GetToken(mystring2, 2) is : #GetToken(mystring2, 2)# </cfoutput> |
GetToken(mystring2, 2) is : ,five,nine,zero:; |