server code commit v1.1

Server end database manipulation code by Leckie, done.
Need to wirte html code for teachers next.