if ($.inArray('yourElement', yourArray) > -1)
{
//yourElement in yourArray
//code here
}
Reference: Jquery Array
The $.inArray() method is similar to JavaScript's native .indexOf() method in that it returns -1 when it doesn't find a match. If the first element within the array matches value, $.inArray() returns 0.