Create dao.class.php

Class is specific to my set up, not yet generalized. In particular requires a history table in the same db