PHP code for JudoDB backend