database php object errors. pre-fix state