Skip to content

Instantly share code, notes, and snippets.

@unknownuser88
Created January 6, 2014 13:25
Show Gist options
  • Save unknownuser88/8282866 to your computer and use it in GitHub Desktop.
Save unknownuser88/8282866 to your computer and use it in GitHub Desktop.
split(delimiter, [limit]) Splits a string into many according to the specified delimiter, and returns an array containing each element. The optional “limit” is an integer that lets you specify the maximum number of elements to return.
//split(delimiter)
var message="Welcome to jQuery4u"
//word[0] contains "We"
//word[1] contains "lcome to jQuery4u"
var word=message.split("l")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment