how to remove duplicate objects from json array in java code example
Example: Remove Duplicate objects from JSON
//change is
while( $row = mysqli_fetch_array( $result ))
{
$response[] = $row;
}
//with this
while($row = mysqli_fetch_array($result))
{
$response['id'] = $row['id'];
$response['name'] = $row['name'];
$response['password'] = $row['password'];
$response['email'] = $row['email'];
}