array_compare javascript function