You are here: Re: Photo Gallery Display question « PHP Language « IT news, forums, messages
Re: Photo Gallery Display question

Posted by Connector5 on 12/08/05 17:42

echo "<table>\n";

$picnum = 0;
$maxpics = 25;

while (($record = mysql_fetch_assoc($result)) && ($picnum < $maxpics))
{
if (($picnum / 5) == floor($picnum / 5))
{
echo "<tr>\n";
}

echo "<td>\n";

// GENERATE THUMBNAIL HERE

echo "</td>\n";

if (($picnum / 5) == floor($picnum / 5))
{
echo "/<tr>\n";
}

$picnum += 1;
}

echo "</table>\n";


"Jon" <jonra@netins.com> wrote in message
news:dn9g8n$drg$1@news.netins.net...
> All,
>
> I'm putting the final touches on a MySQL/PHP driven photo gallery I have
> built, and am down to one last task. I need to be able to display
thumbnails
> from the gallery in rows of 5 on the main gallery page. I've found many
> scripts out there that do this, but can't find one that works when the
photo
> data (fileName in this case) is coming from a MySQL DB where I need to
loop
> through values in a set of records. Does anyone have a script for doing
> this? Or maybe can throw me the algorithm I'll need to use? Thank you in
> advance.
>
>

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация