Illegal offset type error when => value is omitted
- by thomas
Line 3 of the code below fails if I omit the => $v portion. I get the following error:
Warning: Illegal offset type in /home/site/page.php on line 404
When the [$k] in line 5 is changed to ['$k'], i receive the following error.
Notice: Undefined index: $k in /home/site/page.php on line 404
When it is like below with the the full $k => $v…