I have a function that returns an array from the database from which I have to display some data into the view.
If I do
print "<pre>";
print_r($names);
exit();
on the variable that stores the data it returns this:
Array
(
[0] => Array
(
[nume] => Eugen
)
[1] => Array
(
[nume] => Roxanescu
)
[2] => Array
(
[nume] => Georgiana
)
[3] => Array
(
[nume] => Andrei
)
)
I can't change the function I talk about in any way, I need to store each name in a different variable. At the end it should look like this:
name1 = "Eugen"
name2 = "Roxanescu"
name3 = "Georgiana"
name4 = "Andrei"
Thank you very much!
$name1 = $names[0]['nume'];and so on?numeFROMrummy_usersLEFT JOINrummy_gamesONrummy_users.id_user=rummy_games.id_userWHERErummy_games.id_joc=".$id_joc.".