Escaping pound (#) symbol for CF ajax post

Almost everyone out there who uses CF knows that in order to escape the # symbol just simply make add another # so it looks like so "##".  But what if it's coming from a POST value; say from a form using Ajax?

For example my string looked like this 'myInputs=&myInputs1=#+<89Rtiahsdf>1&myInputs2=34jarlfkj7&#' My goal was to remove 'myInputs', '=' and the '&' symbol then separate everything putting it into an array.

postion one  = #+<89Rtiahsdf>;1
postion two = 34jarlfkj7&#

The string above has two issues with it one it has pound symbols which CF will throw an error if encounters one and there is not a closing one. Second notice the & at the end or the string, well that little beauty caused me to have 3 entries instead of two.

The first step was to take my string and use the JS replace function with some simple RegX. The replace function will look for the # function by adding /#/ tells regX to look at # and the g tells the regX to look for every instance, other wise it will just do the first it encounters.

So what this did was add double ##'s to my string making it look like this.

myInputs=&myInputs1=##+<89Rtiahsdf>;1&myInputs2=34jarlfkj7&##

Now for the CF part once the string is passed into CF using the following commands.

<cfsetanswers='myInputs=&myInputs1=##+<89Rtiahsdf>;1&myInputs2=34jarlfkj7&##'/>

remove all the + and replace with a space
<cfsetanswers=Replace(#answers#,'+'," ","All")/>

remove all myInputs=   
<cfsetanswers=ReReplaceNoCase(#answers#,'myInputs=',"","All")/>

remove all myInputs that begin with & and end with a number and = sign then put into list and with ^* as separator.
<cfsetanswers=ReReplace(#answers#,'&myInputs[0-9]=',"^*","All")/>  
originally I had the commented out one below but it removed all & and actually made my answers 3 instead of 2
<!---remove & and add ^*--->
<!---<cfset answers = ReReplaceNoCase(#answers#,'&',"^*","All")/>  --->    

Set the list to an Array
<cfsetarrAnswers2=listToArray(answers,"^*")/>

<cfdumpvar="#arrAnswers2#">

Clean Array

Condensed my code looks like this.