Photo Gallery

I found a tutorial on how to create a photo gallery. Basically, all images will be moved to a certain folder and its file name will be stored in the database. Do you think that would be okay? How about thumbnail?

What is the point of separating name and extension?

The thumbnail will also be stored on the file system, and it’s name recorded in the DB.

That sounds good. I personally use 2 fields for images, “name” and “extension”.

Then when you query the database you can use echo ‘images/’.$row[‘image_name’].‘.’.$row[‘image_ext’];

etc.

I would say it depends what you are using the photos for.
If you are just displaying them then I would go for putting them in a folder and use a simple piece of code to display them - you could also create a text file for each one with a description if you want.
If you are adding comments, displaying by catagory etc. I would go for a database method.