Split a string into substrings using the specified separator and return the substrings as an array.
SyntaxstringObj.split([separator[, limit ]])
The result of the split method is an array of strings split at each point where separator occurs in stringObj. The separator is not returned as part of any array element.
ExamplesThe following example illustrates the use of the split method.
var s = "The quick brown fox jumps over the lazy dog.";
var ss = s.split(" ");
for (i in ss) {
document.write(ss[i];
document.write("<br/>");
}
See also Other articles
Attributions
Microsoft Developer Network: Article
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4