You are here: Re: [PHP] Re: previous + next buttons, no DB « PHP « IT news, forums, messages
Re: [PHP] Re: previous + next buttons, no DB

Posted by "Ashley M. Kirchner" on 10/19/23 11:24

Jeff Loiselle wrote:

> Ashley,
>
> How are you creating the gallery page? You must be reading the
> filenames in the directory and producing an <img> for each one. Can
> you create an array of those filenames, save it to session (or
> generate it each time), and iterate through them?
>
Say the images are in a folder called /gallery/

Within that, I have an index.php that is manually coded to have
thumbnails of the images displayed in a grid. Important to note:
they're in a very specific (artistic) order. Each one of those
thumbnails is linked to one and the same popup.php file that is simply
another php file that expects an $ID passed to it. That $ID, which
again is hard coded in index.html, tells popup.php which file to
display. (that $ID is basically the file name of the image, so I can
append it to the <img /> tag as the page loads.

So you see, I have no array of anything. The index.html file gets
manually edited every time something is added or removed. This is why
I'd like a programmatic way of a) generating that file, so that the
client can add/remove images as they see fit, and b) be able to have
prev/next buttons on the popup window.

Does that make sense?

--
R | I haven't lost my mind; it's backed up on tape somewhere.
+--------------------------------------------------------------------
Ashley M. Kirchner <mailto:ashley@pcraft.com> . 303.442.6410 x130
IT Director / SysAdmin / WebSmith . 800.441.3873 x130
Photo Craft Laboratories, Inc. . 3550 Arapahoe Ave. #6
http://www.pcraft.com ..... . . . Boulder, CO 80303, U.S.A.

 

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

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