In a quick blog post today Stuart Herbert asks the community at large a question - should is_array accept an ArrayObject?
Hereâ€™s a quick question for the wider PHP programming community â€¦ if youâ€™re writing code that tests for the presence of an array, should is_array() also accept objects that behave like arrays?
Some quick code snippets show that, currently in PHP 5.2, an is_array test will return false. If you use an instanceof to check it, however, you can get it to return true. There's plenty of comments on the subject with quite a few "no"s in the group.