Answer the question
In order to leave comments, you need to log in
How to replace the array_rand function and access the array one by one?
There is a code
/// пример массива
$GLOBALS['test'] = [
[
'id' => 30009,
'url' => 333222,
],
[
'id' => 33351,
'url' => 555666,
]
]
///вывожу рандомно часть
$zapros = $GLOBALS['test'][array_rand($GLOBALS['test'])];
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question