Ngo Thi Hong Nga wrote:
Hi, I want to split the words seperated by character
"|".
<%
String[] sources=new String("hello|world").split("|");
for (i in 0..<sources.length)
{
print sources[i]+"<br/>"
}
%>
but the result is:
h
e
l
l
o
|
w
o
r
l
d
I tried using String[] sources=new String("hello|world").split("\|");
but it
gives me error.
How to solve this problem?
split("[|]")
--
Sergiu Dumitriu
http://purl.org/net/sergiu/