|
Posted by macca on 09/17/07 16:07
> > Some code I had was working, now it tells me "Cannot use string offset as an
> > array"
sounds to me like you are trying to travel through a multidimentional
array and specifying two keys in one array.
e.g.
if i had an array something like
$array = array (0=>1,
1=>2,
2=> array ('a'=>1,
'b'=>2,
'c'=> array ('foo'=>70
'bar'=>80,
'baz'=>100)
and i said $array[2]['b']['c']['baz'] i would get "Cannot use string
offset as an array"
when i should have said $array[2]['b']['baz']
Navigation:
[Reply to this message]
|