awesome, thanks.

>>> [EMAIL PROTECTED] 20/10/2006 11:33 am >>>

JSStringFormat()

Will escape everything you need

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of Scott Thornton
Sent: Friday, 20 October 2006 11:28 AM
To: [email protected] 
Subject: [cfaussie] OT: Javascript equivalent to PreserveSingleQuotes?


Hi,

I keep getting caught out when assigning a value to a form element from a
database query when it contains a single or double quote. I usually
#Replace# them with empty strings, but I'd much rather preserve the
formatting of the text

Is there an equivalent of something like PreserveSingleQuotes to allow this
kind of thing to happen.

This value will then be inserted or updated into the database.

Example..

window.parent.document.forms[1].SOMEFIELD.value = "#QUERY.SOMEFIELD#";

actually, the above example allows single quotes eg O'Brien, but does not
like double quotes, eg "Kirribily House"





Scott Thornton, Programmer
Application Development
Information Services and Telecommunications
Hunter-New England Area Health Service
p: +61 02 49213589
m: 0413800242









--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cfaussie
-~----------~----~----~----~------~----~------~--~---

Reply via email to