Hi all,
While browsing some php code yesterday I found out that it was possible to store images in a database in the form of 'blobs'.
I currently have a website that allows members to upload a profile picture of themselves. The pictures are renamed with a time/date hash and the link to the users picture is stored in the database. The actual thumbnail itself is stored as a jpg in a folder.
My question is this...
From a scaleability point of view, is this the right way to be doing this? I currently have around 1500 members with about 50 new ones joining every day. The site is really beginning to take off and I'm wondering whether a better way would be to store the pictures themselves in the database?
What are the pro's and con's of this??
I notice in myPhpAdmin that it will only allow me to export/import a max of 50Mb so I'm thinking that this would be used up a lot quicker if I store images in the database.
However, I'm also unsure of how many images I can hold in the folder and what effect, say, 50,000 or 500,000 images would have in one folder??
Can anyone give me any advice on the best solution for this?
I wondered how facebook do it as they have obviously got millions of user profile pictures to deal with....??
Many thanks for any help you can give me
Cheers
John
