关于字符串转成数组的问题?
请问有谁知道用CFM如何将字符串,
比如1,2,3$4,5,6$ 转成数组{{1,2,3},{4,5,6}}吗?
谢谢!
[解决办法]
<cfset a = "1,2,3$4,5,6">
<cfset b = listtoarray(a, "$")>
<cfloop from="1" to="#arraylen(b)#" index="key">
<cfset b[key] = listtoarray(b[key])>
</cfloop>
<cfdump var="#b#">