Editing an element within an array

From: Date: Wed, 10 Oct 2007 13:14:51 +0000
Subject: Editing an element within an array
Groups: php.general 
Request: Send a blank email to php-general+get-263027@lists.php.net to get a copy of this message
I have a two-dimensional array that looks like this: array( array(0, 123), array(0, 234), array(0, 345), array(0, 456) ) I want to REMOVE any element that contains 234, and I want to INCREMENT the first value for any element that contains 345, to make it look like this: array( array(0, 123), array(1, 345), array(0, 456) ) A pint of cachaça to he who sets me on the path to success.

« previous php.general (#263027) next »