in reply to Re^2: glob quietly fails
in thread glob quietly fails

Actually I think your iterator solution is not half bad. It could work very well where nested foreach loops are not an option.

I'd drop the redundant array_limits array, however.