Funkcja PHP mysqli_fetch_all ()
$returnResult = []; //initialise empty array
while($row = $result->fetch_assoc())
{
$returnResult[] = $row;
}
Codemaster
$returnResult = []; //initialise empty array
while($row = $result->fetch_assoc())
{
$returnResult[] = $row;
}
$array = array();
while($row = $result->fetch_assoc())
$array[] = $row;