note 42703 deleted from function.unset by cmb

From: Date: Mon, 13 Jun 2016 22:27:26 +0000
Subject: note 42703 deleted from function.unset by cmb
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-205715@lists.php.net to get a copy of this message
Note Submitter: bond at noellebond dot com ---- Note that though global arrays will not be altered by a function, an array in an object WILL be altered if referenced within one of its methods. For example: function remove_index ($i) { unset($this->test_array[$i]); $temp_array = array_values($this->test_array); $this->test_array = $temp_array; } Will remove key $i from the object's array and reindex it.

« previous php.notes (#205715) next »