created data layer for PHP & MySQL