You can use the jsStringFormat() function to escape any special JS
characters.

> -----Original Message-----
> From: Edwards Robert (air0rae) [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, August 22, 2002 7:28 AM
> To: CF-Talk
> Subject: Problem with "\" in a Javascript/Query
>
>
> I have a page that populates a combo box via javascript.  The data that is
> returned from a query is (quotes included)
> "\\somemachine\somedir\some.exe".
> The Javascript sets the value via the code new
> Option('"\\somemachine\somedir\some.exe"','"\\somemachine\somedir\
> some.exe"'
> ) (that's the double quotes within single quotes if it's not too clear).
>
> The problem is, it translates out to \somemachine
> omedirsome.exe
>
> (the somedirectory begins with a t, so I'm thinking that it's
> translating it
> to a tab character).  When I pass the selection to another page, it passes
> the tab and the formatting as translated, what I need is for the
> slashes and
> characters to be passed as that are in the DB.
>
> Is there anything I can do with regex or something to keep the slashes the
> way they are?  Kind of like PreserveSingleQuotes.
>
> TIA,
>
> Rob Edwards                   Phone:  (502) 359-1627
> Systems Management Tools   Pager:     (502) 478-1116
> United Parcel Service         Fax:    (502) 359-0094
> EMail:        [EMAIL PROTECTED]
>
> (2B || !2B) == ?
>
>
> 
______________________________________________________________________
Get the mailserver that powers this list at http://www.coolfusion.com
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to