Re: [OT] displaying \n in html?

2003-03-04 Thread Eddie Bush
... 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,

RE: [OT] displaying \n in html?

2003-03-03 Thread Jarnot Voytek Contr AU HQ/SC
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, br); which is a short way of writing: Pattern.compile(\\n).matcher(str).replaceAll(br); also a one-liner... -- Voytek Jarnot Quidquid latine dictum sit, altum