Greetings,
I am trying to save, upload photos to sql db using asp.net mvc core. I think I was able to upload the photo correctly because it states binary data in sql table.
While coding out the display part it just shows a x where the photo is. Here is the code i used to display the image.
var base64 = Convert.ToBase64String(item.BusLogo);
var imagesrc = string.Format("data:image/png;base64,{0}", base64);
<img src='@imagesrc' style="max-width:100px;max-height:100px" />
If anyone know a way to do to this please reply.