public static function inArray($needle, $haystack, $index)
    {
        foreach($haystack as $element)
        {
            if($element[$index] == $needle) return true;
        }
        return false;
    }
public static function inArray($needle, $haystack, $index)
    {
        foreach($haystack as $element)
        {
            if($element[$index] == $needle) return true;
        }
        return false;
    }
public static function inArray ( $ needle , $ haystack , $ index ) { foreach ( $ haystack as $ element ) { if ( $ element [ $ index ] == $ needle ) return true ; } return false ; }
Function to search in array

@access  public
@param   mixed   $needle
@param   array   $haystack
@param   string  $index
@return  boolean
Function to search in array