remote file tranfer with progress bar

76 views
Skip to first unread message

flickle1

unread,
Dec 7, 2009, 12:04:18 PM12/7/09
to PHP Hacks
I need to be able to transfer files from one server to the next.

1. Transfer/Copy the files automatically from the external server to
my local server
2. During the process be able to use a progress bar to watch the
progess (for the larger files)

I know various ways of transferring data from server to server and i
know how to use the following to do so:

Curl
Copy()
Fopen()
File_contents()

The problem is how do i create a progress meter to watch long
downloads.

.......

I have seen many solutions on the internet but they all have the same
thing in common.
They work using a standard upload form. I need it to work from a
database given filename
such as:

www.externalwebsite.com/thisfile.csv

there is about 200 hunderd files that need downloading/transfered from
server to server on a regular basis, to update my local data.

an upload form just would not be appropriate for this.


(Its like i can do the transfers easily even whilst using database
trigger information)
but the problem is i cannot work out how to create a progress bar for
remote file transfer
as apposed to the common. manual upload forms that do the similar
process)


just to note i am aware of all the javascript, jquery, flash,
java, .net and similar standard upload scripts with progress bar. i do
not require a form, i just require collecting transfer information
during a transfer.

any method is fine as long as it can be fully automated...

if any can help me this would be perfect.

Thanks

Daniel Lee

Eliezer Escobedo

unread,
Dec 7, 2009, 10:22:18 PM12/7/09
to php-...@googlegroups.com, PHP Hacks
Newbie!
Lol. J/k ive seen that progress bar thing you tell about in a php
script called rapidleech but it relies also on JavaScript.

My help its just that, download rapidleech from hotscripts.com and
look at the source code. (:

Enviado desde mi iPhone
> --
>
> You received this message because you are subscribed to the Google
> Groups "PHP Hacks" group.
> To post to this group, send email to php-...@googlegroups.com.
> To unsubscribe from this group, send email to php-hacks+...@googlegroups.com
> .
> For more options, visit this group at http://groups.google.com/group/php-hacks?hl=en
> .
>
>

Eliezer Escobedo

unread,
Dec 7, 2009, 10:38:50 PM12/7/09
to php-...@googlegroups.com, PHP Hacks
Oh and the automation would just require a cronjob for a php script
that puts cav info into an array. (:

Enviado desde mi iPhone

El 07/12/2009, a las 11:04, flickle1 <mrdan...@live.com> escribió:

^Lestat

unread,
Dec 8, 2009, 4:08:04 PM12/8/09
to php-...@googlegroups.com
This is an interesting one. If I had some extra time, I would enjoy working this out. But here's what I'm thinking...

Get the total value of all the file sizes in the dir, then as they transfer you can out put X Kb of total Kb transferred. You could display it graphically using something like jQuery and ajax calls. Haven't done it myself, but its a thought.

Reply all
Reply to author
Forward
0 new messages