[fwd] [thelist] Replacing Carriage returns in Javascript

.jeff jeff at members.evolt.org
Mon Sep 17 20:58:59 CDT 2001


dave,

><><><><><><><><><><><><><><><><><><><><><><><><><><><><><
> From: Dave Dufour
>
> I have an application in which I need to replace
> carriage returns/line feeds with a little-used
> character that can be converted back by another
> script.
><><><><><><><><><><><><><><><><><><><><><><><><><><><><><

what, per chance, is the need to convert carriage returns and line feeds?

><><><><><><><><><><><><><><><><><><><><><><><><><><><><><
> I know about the string.replace() function, [...]
><><><><><><><><><><><><><><><><><><><><><><><><><><><><><

is this publicly accessible?

what level of browser are you looking to support?

what are you planning on doing to make sure it doesn't throw errors on
browsers that don't support the replace() method?

><><><><><><><><><><><><><><><><><><><><><><><><><><><><><
> [...] but I have no idea how to refer to carriage
> returns and line feeds.  In VBScript there is CHR(10)
> and CHR(13).  What is the equivalent in Javascript?
><><><><><><><><><><><><><><><><><><><><><><><><><><><><><

\n

good luck,

.jeff

http://evolt.org/
jeff at members.evolt.org
http://members.evolt.org/jeff/






More information about the thelist mailing list