View Full Version : Show only one large photo

Denver Dave
01-23-2003, 05:06 PM
I'm not sure if this is the best section for this discussion - if not please move it. My client ( I don't necessarily agree ) wants the first viewlisting page to show only one somewhat larger photo. Most of the functions seem to retrieve all photo's for the listing - I need the first one.

I think I've talked the client into ~20k images 400 wide by ? high, so I'm considering that rather than having a 3rd image 200 wide by ? high to just resize (by html) the larger image for display and maybe the popup full size will be quite fast. I usually don't like to shrink the file sizes by html display because the full file size must load, but maybe in this situation it might be best, because the desired display size might keep changing.

Anyone have ideas here?
I'll just add items that I figure out here, in case others are interested.

The following sql seems to give me the file information that I will need:
SELECT file_name FROM `listingsImages` where listing_id = 1 order by 'rank' limit 1

I'll just substitute $listingID for 1 and proportionately resize the images and .. should be close.

01-24-2003, 02:11 AM
The best way to do it is to impliment zayitas mod for 1 big picture and rest all small pictures. the mod is at at http://jonroig.com/freecode/phpBB/viewtopic.php?t=862&highlight=&sid=98c7d86f9412d51 fed5676e062e2d15d.. With this mod you will be able to use the 1 big picture or remaining smaller pictures. it is two seperate functions one for big picture and one for smaller pictures.

Denver Dave
01-24-2003, 11:47 AM
Sounds great - thanks. Jon's bbs seems to be down at the moment... I'll check it out when it is back up.