I have a code like this:
if (action == \'John\' || action == \'John Beckham\' || action == \'Henry John\'){ alert(\'true!\'); }
How do I m
Make an array as below.
var newAry = array('a','b','c');
Now just check it as below.
$(function() { var newAry = Array('a','b','c'); if($.inArray(action,newAry)){ alert(action); } });