任意の位置から多次元配列にアクセスする方法はありますか?例: $title = $arr[2][2]; // which outputs Some Title Two
をそして、我々は取得したい場合:私たちは例えば、2項目のIDを持っていると、その項目のタイトルを取得したい場合 $arr = array (
1 => array (1, 'some-url-one', 'Some T
次の例では、匿名関数内から 'str'値にアクセスできますか? $foo = array(
'str' => 'THIS IS A STRING',
'fn' => function() {
// is it possible from within here to access 'str'?
}
);