insert photos to db