db->getRows($this->db->q('SELECT * FROM musicbrainz.bh_artist WHERE name = \''. $name .'\'')); if ($artist_info) { $ids = array(); foreach ($artist_info as $item) { if ($item['id'] == $artist_info[0]['id']) { $ids[] = $item['credit_id']; } return $ids; } } else { return false; } } }