$key = array_search('100', array_column($userdb, 'uid'));
function arraySort($input,$sortkey){ foreach ($input as $key=>$val) $output[$val[$sortkey]][]=$val; return $output; }