Well I did see I missed a global there. But that certainly should not cause a dump file. Dump files are caused from PHP or apache crashing on the server. There's nothing in the code that should do that though. You don't have to use the code though. The idea is to see how it's done, and add to your code what you need.