cflocation dropping characters
Specifically it's dropping the ampersand "&" and all characters after this.
I have a simple search form that sends the search item to an action page where depending on what variables are sent it either processes the form or sends the variable in the url to another page to get processed.
The form sends the variables correctly to the processing page. Using cfdump I see I'm getting the correct search item. Then I use cflocation to send the search item to a different page for processing but at this point on the third page the variable is missing anything behind the ampersand. "A&B" becomes "A"
My processing page looks like this.
<cfif IsDefined("form.how") and #form.how# eq "any">
<cfset theitem = #trim(form.item)#>
<cflocation url="search.cfm?item=#theitem#" addtoken="no">
</cfif>
I receive "A&B" on this processing page but on the search.cfm page when dumping out the url variable I receive "A" and everything beyond and including the & is stripped.
I've tried setting the item variable as a session variable on the processing page but that didn't work either. I've tried using a meta refresh tag but got the same results. I've googled and do not see anything on this.
The "&" sign should be a valid character to search for in the database.
Any suggestions? thanks
