solved writing image to db - problems with reading image from db into a src tag