Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PostgreSQL project

Status
Not open for further replies.

DeepBlerg

Technical User
Jan 13, 2001
224
0
0
AU
In a few months time I will be creating a site and I'd like to use PHP & PostgreSQL because of their flexibility.

The site will consist of some 200 - 300 images all the same size, displayed alphabetically (10 per page or all per letter depending on how the user wants to view them). Occassionally new images will be added so that won't be a problem since the pages won't be static, instead created on-the-fly.

My question is how will I create this solution? Should I store the image names in the database and call 10 or all at a time depending on what the user wants?

All I basically need is a few pointers since I am new to PHP & PostgreSQL.

Thanks in advance.
 
I'm new to PostgreSQL too, but in my experience with DBMS, generally you want to store the image names in the database, and not the actual images themselves. It usually makes things a whole lot quicker.

As for the solution, I think you're going in the right direction. Only call what the user needs, so if the user clicks on 'A', bring up the A images.

Typically you want to minimize the amount of loadtime for the webpage. A good way to minimize it would be to reduce the number of images loaded. Show 10 at a time, and have a 'next 10' link at the bottom. If your images are just thumbnails, then you can probably show more than 10 per page. Just keep the bandwidth limitations in mind, and you'll be fine.

hth
leo
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top