Remove an item by value in an Array object

by Mohan 2012-09-20 23:30:21


________________________________________
Remove an item by value in an Array object
var arr = ['a', 'b', 'c', 'd'];
var pos = arr.indexOf( 'c' );
pos > -1 && arr.splice( pos, 1 );
Print( arr ); // prints: a,b,d
________________________________________



423
like
0
dislike
0
mail
flag

You must LOGIN to add comments