That depends on him having a certain JDK. Was that introduced in 1.3 or
1.4? I think it was introduced in 1.4. I know I cut some code for
someone that didn't have as modern of a system as myself and I wound up
going back and doing free work to fix it, so it hasn't been around
forever :-(
Oh :-) and ... my preivous post might also explain why you've had so
many questions go unanswered. You see, people here expect you to do
your homework. Then, most folks go for the interesting or
mission-critical problems. You see, none of us are getting paid to
solve your problems, and we
David Graham [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
i'd love to see one-liner that converts char to string.
return newlineString.replaceAll(\n, br/);
which is not very backward compatible, i am still at 1.3
Then use the jakarta lang package to acheive the same result in one line of
code.
David
From: dario [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: displaying \n in html?
Date: Tue, 4 Mar 2003 19:13:11 +0100
David Graham [EMAIL
... a handy trick. Thanks for speaking up. I wasn't aware there was
such a straight-forward way of doing it before JDK 1.4!
Jarnot Voytek Contr AU HQ/SC wrote:
firstly, this is OT, secondly if you're using JDK 1.4, here's your one-liner
(String in question is str):
str = str.replaceAll(\\n,
David Graham [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
LOL
David
yeah, right, i could have expected so. i sent about five questions to this
mailing list and i never NEVER got an answer. and i don't think that the
reason is i ask stupid questions, in fact most of the
viditur.
-Original Message-
From: dario [mailto:[EMAIL PROTECTED]
Sent: Monday, March 03, 2003 12:46 PM
To: [EMAIL PROTECTED]
Subject: Re: displaying \n in html?
David Graham [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
LOL
David
yeah, right, i could
i'd love to see one-liner that converts char to string.
return newlineString.replaceAll(\n, br/);
David
_
The new MSN 8: smart spam protection and 2 months FREE*
http://join.msn.com/?page=features/junkmail
i allways store new line char in string as \n, because i never know where
is it going to be displayed (console,webpage,etc...), but when i need to
display it in web page it shoud be converted to something like br
(although w3c doesn't recomend using br, i don't understand why) pre
doesn't work for
Struts doesn't provide that feature. You're too lazy to write a one line
method that does it?
David
From: dario [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: displaying \n in html?
Date: Sun, 2 Mar 2003 19:57:11 +0100
i allways store
On Sun, 2003-03-02 at 13:57, dario wrote:
i allways store new line char in string as \n, because i never know where
is it going to be displayed (console,webpage,etc...), but when i need to
display it in web page it shoud be converted to something like br
(although w3c doesn't recomend using
LOL
David
From: Dave Newton [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: Re: displaying \n in html?
Date: 02 Mar 2003 14:15:07 -0500
On Sun, 2003-03-02 at 13:57, dario wrote:
i allways store new line char
12 matches
Mail list logo