added phpdbg_write to replace all  the printf