Reputation: 121
I want to remove the number indexes in the following output
Array ( [0] => 7593 [id] => 7593 [1] => Atakan [ad] => Atakan [2]
intended
Array ([id] => 7593 [ad] => Atakan [2]
my code
global $durum;
$array = Array();
$sql="select * from bird_table_uye order by id desc";
$query=phpmkr_query($sql,$durum);
$i=0;
while ($row=phpmkr_fetch_array($query)) {
$array[$i]=$row;
$i++;
}
print_r($array);
Upvotes: 0
Views: 66
Reputation: 1202
You can use
mysqli_fetch_array()
rather using
mysqli_fetch_assoc()
Upvotes: 3