DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR JAVASCRIPT
javascript split string into array by comma and space
input.split(/[ ,]+/); //splits string using RegEx on a space OR a comma
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#javascript
#split
#string
#array
#comma
#space
ADD COMMENT
Topic
COMMENT
Name
2+1 =
Submit