Re: Download code



Shelly wrote:
"Jerry Stuckle" <jstucklex@xxxxxxxxxxxxx> wrote in message news:W-ednUfe0eT3P3_bnZ2dnUVZ_tajnZ2d@xxxxxxxxxxxxxx
Sheldon Glickler wrote:
I have a set of jpg files on a page. I want to give the user the option to downloadd all of them at once. What is the code to do that? It must exist because many times users are presented with a download button and there must be something behind it. Even if it is one file at a time, I can loop through the list. As for a name, I can use the current name and if it is one at a time, then the user can name each one.

Alternatively, I could zip it up into one file and then have the download.

So, I have two questions:

1 - What is the code to download a file to the user's computer?
2 - How do I zip up a set of jpg files on the server?

Shelly
Of course you do know they can always download an image by right-clicking on the image and selecting "Save Image..." (or whatever wording their browser uses) option. No PHP required.

Of course I know that! However, most users are not overly computer literate and I would have to give them explicit instructions on what to do. A button saying "Download" is much easier on the SU. (stupid user). Also, I would like to have a button that says "Download All Pictures". For either of these I need code behind the button submit.

Shelly



I just put a note on the page as to what to do. Even the least-knowledgeable users can figure that out.

But you'll have to zip the image(s) to ensure they are downloaded. Otherwise the client browser may just display the image. You can't control that from the server end.

For building zip files, you can start with:

http://www.php.net/manual/en/ref.zip.php


--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@xxxxxxxxxxxxx
==================
.



Relevant Pages

  • Re: Problem Updating New Messages from NTTP News Server OE
    ... > as far as I know and he doesn't have a server in his setup. ... download the answer to a problem he had posted in the Outlook group and I had seen the answer almost immediately on July 1. ... sure how taking the check out of the download headers boxes would have helped. ... pane 3) Get headers at a time 4) No check in mark all messages as read when exiting newsgroup ...
    (microsoft.public.windows.inetexplorer.ie6_outlookexpress)
  • Re: [opensuse] Re: why /var/run and /run these two directories have absolutely the same contents?
    ... look and feel to Windows anyway; ... all or specific folders to download from the IMAP server to a local ...
    (SuSE)
  • Re: OL2003 OAB: Exceeded the download limit set by your administra
    ... 13:50:37 Sam Jones: Synch operation completed ... reference to Outlook Verbose Logging. ... Sort Locale being used by the server is: ... trying to download the OAB then closing Outlook ...
    (microsoft.public.exchange.clients)
  • Re: SUS
    ... > I have setup a SUS Server on win2k. ... 0-2.reg will not configure your machine to automatically download updates from ... critical updates or service packs that your machine needs. ... It will also ask you if you want to install them, ...
    (microsoft.public.windows.server.general)
  • Re: OL2003 OAB: Exceeded the download limit set by your administra
    ... 13:50:37 Sam Jones: Synch operation completed ... reference to Outlook Verbose Logging. ... Sort Locale being used by the server is: ... trying to download the OAB then closing Outlook ...
    (microsoft.public.exchange.clients)