In article <000701c1df50$0e2a1060$[EMAIL PROTECTED]>, [EMAIL PROTECTED] 
> I'm building a site that will eventually hold several hundred photos. (Kids
> soccer photos.)  The first page will display a table of 9 thumbnails, with
> buttons at the bottom to move 9 forward or 9 back (after the first 9, of
> course).
> The names of the files will be in a MySQL database and the pages built in
> PHP. (This should satisfy the topic-sensitive on this list.)
> Would it be better to:
> Gather all of the names in one PHP array, thus having only one MySQL call,
> and pass that array as a hidden value using $PHP_SELF
> Or would it be better to have the page pull the data using LIMIT to pick the
> portion to display?
> We are not talking a high-volume site, perhaps a dozen people at one time.
> John Hughes
No contest - use LIMIT. It also avoids the potential problem where 
additional images are added whilst someone is cruising the db; and 
depending on the size of the data you are apssing, there may be potential 
hiccups. On the other hand, if you only need to pass the current position 
in the list....

David Robley
Temporary Kiwi!

Quod subigo farinam

PHP Database Mailing List (
To unsubscribe, visit:

Reply via email to