Demo For: Javascript Check If A Value Is In An Array Examples

Here are the contents of 1st array:

var my_array1 = Array('apple', 'grapes', 'mango');	

Here are the contents of 2nd array:

var my_array2 = Array('apple', 'grapes');