removing all duplicate values from an array
From: Allowee (Vincent_at_GeversXL.nl)
Date: 10/30/03
- Next message: Jackson Miller: "OOP, dynamic class extention"
- Previous message: Curt Zirzow: "Re: [PHP] Copying an uploaded file..."
- Next in thread: Mike Migurski: "Re: [PHP] removing all duplicate values from an array"
- Reply: Mike Migurski: "Re: [PHP] removing all duplicate values from an array"
- Reply: Kevin Stone: "RE: [PHP] removing all duplicate values from an array"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: php-general@lists.php.net Date: Thu, 30 Oct 2003 18:27:51 +0100
Hi,
I'm looking for a function that does almost the same as array_unique()
But it must also delete the other duplicate entry.
sample to explain:
array(
'a' => 'one',
'b' => 'one',
'c' => 'zero',
'd' => 'two'
);
I now want the result to be:
array(
'c' => 'zero',
'd' => 'two'
);
This way I will be able to do an array_diff and then see all the duplicate
entries listed.
this is to find dup. ip address for a hosting system,
displaying both accounts will make it easy to trace the amount of accounts 1
ip curruntly has.
Anybody know how to do this?
Thanks,
Allowee
- Next message: Jackson Miller: "OOP, dynamic class extention"
- Previous message: Curt Zirzow: "Re: [PHP] Copying an uploaded file..."
- Next in thread: Mike Migurski: "Re: [PHP] removing all duplicate values from an array"
- Reply: Mike Migurski: "Re: [PHP] removing all duplicate values from an array"
- Reply: Kevin Stone: "RE: [PHP] removing all duplicate values from an array"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|