javascript Array splice( )

splice( ) NN 4 IE 5.5(Win) ECMA 2  

splice(startIndex, deleteCount[, item1[, item2[, ...itemN]]])

  

Removes one or more contiguous items from within an array and, optionally, inserts new items in their places. The length of the array adjusts itself accordingly.

 
Parameters
 
startIndex

A zero-based integer of the first item of the subset from the current array.

deleteCount

An integer denoting how many items from the startIndex position are to be removed from the array.

item1...itemN

Comma-delimited list of JavaScript values to be inserted into the array in place of removed items. The number of items does not have to equal deleteCount.

 
Returned Value

An Array object containing removed items.


278,Nickname,Homepage or email,Comments here,Add comment