Does this existing anywhere in the world? (javascript download progress meter)

J

Julia Briggs

Hello,

I've read quite a bit of discussion on different approaches of how to
create a download progress meter that can be implemented into a Web
site. I understand that by the very nature of the way the download
transport is handled that this cannot "automatically" be done...
upload progress meters exist, but not download. However, I've seen
different theories on how it could be done if one knows the file size.
Is anyone aware of a working download meter script

written in JavaScript?

Sincerely,

Julia
 
R

rf

<DHTML crosspost snipped>

Julia Briggs said:
Hello,

I've read quite a bit of discussion on different approaches of how to
create a download progress meter that can be implemented into a Web
site.

Downloading what? The web page or a file?

If the former then the page has to be downloaded before the javascript runs.
By the time you get to report on it it has already happened.

If the latter then the download process is not even handled by the browser,
it is hived off to a seperate process. Any javascript running in the web
page has no knowledge of this process.

Besides, the download process itself has a progress bar.

What exactly are you trying to achieve?

Cheers
Richard.
 
R

rf

Julia Briggs said:
"rf" <[email protected]> wrote in message
I want to have users who download large PDF documents that are
normally automatically loaded into the browser presented with a
download progress bar.

By the time the browser has launched the adobe plug in and given it control
so it can download the pdf your web page is long gone. The web page being
displayed now is the one containing the pdf (well, the plug in anyway).

Even if you could somehow stay there (by for example loading the pdf into a
second frame while your javascript lives in a first frame) there is no way
you can interrogate the adobe plug in to determine how much it has loaded.
Even adobe may not know how big the file is. A server is not obliged to
provide this information. I doubt that adobe would even care. It would just
read the file till it got to the end of it.

You are better off putting something on your page, near the link, like
<p>This is a 500KB pdf file, it may take a while to download</p>

Your viewer will have some idea about how long such a download should take.

Cheers
Richard.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,766
Messages
2,569,569
Members
45,042
Latest member
icassiem

Latest Threads

Top