You are here: Re: How do you display new images created with PHP? « All PHP « IT news, forums, messages
Re: How do you display new images created with PHP?

Posted by NC on 09/28/93 11:57

Flaming Corncob wrote:
>
> Below is the code I've got:

[skip]

> It works. It takes the $src and creates a smaller thumb
> nail image and outputs it to the browser. There's a problem,
> though. Printing it this way I can't seem to print out more
> than one image in a gallery. If I want to print.. say.. 12 out
> of 40 thumb nail images to the browser in a formatted
> page... using header() seems to not be the way to go. Is
> there any way to "output" the same image to the browser
> without having to use header()?

No. One instance of a script can only output one document (HTML,
image, plain text, PDF, etc.) If you want to display 12 images, you
need to call the same image display script 12 times. For example:

for ($i = 1; $i <= 12; $i++) {
echo "<img src='showimage.php?img_id=$i'>\r\n";
}

Cheers,
NC

 

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

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