example:
Code: Select all
<?php
$test = array('1' => 'foo',
'2' => 'bar',
'default' => $test['2']);
print $test['2']; //bar
print $test['default']; //bar
?>Moderator: General Moderators
Code: Select all
<?php
$test = array('1' => 'foo',
'2' => 'bar',
'default' => $test['2']);
print $test['2']; //bar
print $test['default']; //bar
?>Code: Select all
$test = array('1' => 'foo',
'2' => 'bar',
'3' => &$test
);
echo $test['3']['1']; // "foo"