141
rated 0 times
[
143]
[
2]
/ answers: 1 / hits: 18487
/ 12 Years ago, fri, march 23, 2012, 12:00:00
I want to split a string with all non-alphabetic characters as delimiters.
For example, I want to split this string
hello1 twenty-three / nine.bye
into
[hello,,twenty,three,,,nine,bye]
I've tried this
text.split(/[A-Za-z]+/)
but it isn't working.
How do I split a string by non-alphabetic characters?
More From » string