In my opinion, everything is allowed and shouldn't cause an issue, but there
are some scenarios where you don't expect them or don't want them and you
have to strip them out either on the insert or on the data retrieval.  This
is part of data validation.  It's up to you to determine what *your *rules
are and where/how you want to handle it.

Line Feed: CHR(10)
Carriage Return: CHR(13)

PC Users: <cfset CRLF = CHR(13)&CHR(10)>
Macs/Linux users will be using CHR(10) alone I believe.

Just do a replace(string,CRLF,'','ALL') and you're good to go.

On Jan 21, 2008 12:26 PM, Richard White <[EMAIL PROTECTED]> wrote:

> Hi
>
> just wondering if anyone has done a review on what characters i can allow
> the user to input into form fields that wont cause problems in javascript
> and coldfusion.
>
> for example, if we allow them to enter a carriage return then when we get
> data out of the database, if we use that value in a js array for
> manipulation on the client then it will come up with unterminated string
> literal errors
>
> so i suppose its not just standard characters for standard forms but a
> full review of what characters cause problems in any situation in javascript
> and what cause problems in coldfusion
>
> thanks very much


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;160198600;22374440;w

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:296980
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to