php/database code created last summer