I need a javascript function that can take in a string and an array, and return true if that string is in the array..
function inArray(str, arr){ ... }
you can use arr.indexOf()
http://www.w3schools.com/jsref/jsref_indexof_array.asp