I have a function that returns an values in an array, the problem is that sometimes that array only has a single value in it. If I use a for each loop it fails as there are not more than one row in the array.
I can't use $array as I need the key value as well and this is not always 0. Any ideas on how to get the value out of the array with the key as well.
Code: Select all
foreach($pos as $key => $value)