After executing a prepared SQL statement in PHP, I've doing a fetchAll(). This results in the following array:
Array
(
[0] => Array
(
[ID] => 2
[0] => 2
[latitude] => 38.44560000
[1] => 38.44560000
[longitude] => -99.99999999
[2] => -99.99999999
)
[1] => Array
(
[ID] => 4
[0] => 4
[latitude] => 38.44560000
[1] => 38.44560000
[longitude] => -99.99999999
[2] => -99.99999999
)
)
I would like my array to look like this:
Array
(
[0] => array('2','otheritem1details....','38.44560000','-99.99999999'),
[1] => array('4','otheritem1details....','38.44560000','-99.99999999')
)
Do I have to take the data from the source array and manually compile it into a new array in the correct format? Or is there a way to fetch the data initially in the correct format?
Many thanks.