References and array indexes

From: Date: Thu, 05 Aug 2004 08:14:26 +0000
Subject: References and array indexes
Groups: php.general 
Request: Send a blank email to php-general+get-192813@lists.php.net to get a copy of this message
Hello! The following PHP code: <? $a = array("1"=>"First Element", "2"=>"Second Element"); $v = &$a['3']; print_r($a); ?> has this result: Array( 1 => First Element, 2 => Second Element, 3 => ) Can anyone give me an explanation for this? What is happening in the guts of the PHP interpreter when it gets these instructions? With best regards Gabriel Birke -- KONTOR4_Neue Medien Plathnerstraße 5 30175 Hannover Fax: +49 51184 48 98 99 mailto:birke@kontor4.de http://www.kontor4.de

« previous php.general (#192813) next »