Jump to content

Archived

This topic is now archived and is closed to further replies.

Jim from Oakland

"copy" file from web site to my PC

Recommended Posts

Phreax

On my Windows XP PC my php script iterates through monthly zip files on a public website so it can "copy" them to the directory on my PC containing the script. Here is one of the files.

[a href=\"http://mis.nyiso.com/public/csv/damlbmp/20050301damlbmp_zone_csv.zip\" target=\"_blank\"]http://mis.nyiso.com/public/csv/damlbmp/20...mp_zone_csv.zip[/a]

How do I tell php to put a copy of that file on my PC in the script's directory?

Thanks much!

Jim

Share this post


Link to post
Share on other sites
You won't be able to do it unless you make your computer into a web server, with php installed on it, or install an ftp server on your box. You cannot make your web server go out and "push" files to another computer unless you have ftp.

You could do this all thru command line though and then put it into a scheduled task. It is pretty easy to do. Let me know if you want to do it and I will give you some code.

Ray

Share this post


Link to post
Share on other sites
thanks ray

I gave too little background: I use 4.31 and Apache on my Windows XP system.

And I found that the php copy file system function works fine.


[!--quoteo(post=360450:date=Apr 1 2006, 02:23 AM:name=craygo)--][div class=\'quotetop\']QUOTE(craygo @ Apr 1 2006, 02:23 AM) [snapback]360450[/snapback][/div][div class=\'quotemain\'][!--quotec--]
You won't be able to do it unless you make your computer into a web server, with php installed on it, or install an ftp server on your box. You cannot make your web server go out and "push" files to another computer unless you have ftp.

You could do this all thru command line though and then put it into a scheduled task. It is pretty easy to do. Let me know if you want to do it and I will give you some code.

Ray
[/quote]

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.