i'm having some trouble trying to use a query result as an array
First i run a query to get all the zips that i need
$this->db->select('zip');
$this->db->from('custom_city');
$this->db->join('city_to_zip', 'custom_city.id = city_to_zip.city_id', 'left');
$this->db->where('city_to_zip.city_id', $_POST['city']);
$zip = $this->db->get();
$data['zips'] = $zip;
$zip_array = $zip->result_array();
then the query output is this, when i try to use it.
Now i know it's doing something, because it says "array" 8 times and thats the right count for the query. I just need to know how to get the zip code in there instead of the word array.
AND `zip_code` IN (Array, Array, Array, Array, Array, Array, Array, Array) [/quote]
in my query i'm using...
$this->db->where_in('zip_code', $zip_array);
Thanks,
Jbeasley