There are so many good tutorials out there about inserting an image inside a table in a database, using the FileUpload controller.
Yet I cannot find a good tutorial about how to fetch these images and display them.
When I used to store the image name or path in the database (as a Varchar), It would be very simple by doing something like this...
HTML/ASP:
<img src="" runat="server" id="myImage" />
C#:
myImage.Src = myReader.getValue(0).toString();
The Result:
<img src="/Images/pic.png" runat="server" id="myImage" />
And Voila, the picture will be displayed.
But Now I would like to fetch uploaded images, not a path, means the type of the table column is IMAGE.
Some tutorials will eventually lead to display a picture in FULL SCREEN.
I do not want that, I simply want to fetch and display the image the same way it is displayed in the previous example, with a given size and place inside my web page.
Why am I uploading images to the database? Because these images are "Profile Pictures", not public pictures, I do not want a guest to simply browse for /Images/ to find all the pictures of my web site, public and private.