Vote count:
0
I have an array with completely random key, for example:
$random_array = array (
"randomtext" => "randomvalue",
"apple" => "abc",
"orange" => "bb",
"someothertext" => "blue",
"oxygen" => "bbaa",
"someothertext" => "don't know what is this",
"abcdef" => "bbcc",
"someothertext" => "xxx",
)
So, to loop through the array, foreach loop is a must. However, I want to get 2 records in each loop do some processing. Is there a way to do so?
asked 1 min ago
Do I have a way to get multiple record in one foreach loop in PHP?
Aucun commentaire:
Enregistrer un commentaire