Updated PHP next() builtin function to check for array type

- Now raises correct E_WARNING when non-array value is specified