Cynosure.X International LLC

:

Add Comment | Related Links | TrackBack
Related Content

WebCopy.php (GPL)

WebCopy.php is another one of those scripts that I had to rewrite, because my original Java version (see elsewhere on this site) doesn't run on the new web hosting service.

WebCopy.php is a PHP command-line script that helps you copy a web page to a local file. It only accepts two parameters: 1) the URL; and 2) the file name.

Unlike the Java implementation, this implementation of WebCopy over-writes the file if it exists. I've been debating back-and-forth when I use the Java version, whether it's better to over-write or better to report and exit. We'll try it the other way with this PHP script and see how it goes.

WebCopy.sh is distributed as executable source code under the GNU General Public License. Please see the license agreement elsewhere on this site.

Attached File: WebCopy.txt (553 B)

Chieh Cheng
Fri, 29 Jun 2007 14:47:54 -0700

The previous version of WebCopy.php has trouble downloading some web pages. Attached to this message is a new, updated version of WebCopy.php that fixed that bug.

Attached File: 1 - WebCopy.txt (810 B)

Chieh Cheng
Wed, 08 Aug 2007 08:31:38 +0000

Previous versions of WebCopy.php has a limit on the size of the web page you download. On my computer, that limit was just over 8 megabytes. I've now modified WebCopy.php so that there is no limit. With this latest version of WebCopy.php, you can download any sized web pages. The file size is only limited by the hard drive partition format. For example, FAT32's file size limit is 2 GB.

Attached File: 2 - WebCopy.txt (716 B)

Chieh Cheng
Sun, 12 Aug 2007 06:56:18 +0000

In this latest version of WebCopy.php, I've made slight optimization so that the output file doesn't have to be reopened every time the read buffer is full. It should speed it up slightly and use your disk a little less.

Attached File: 3 - WebCopy.txt (712 B)

Chieh Cheng
Thu, 03 Apr 2008 22:24:42 +0000

The original intent of WebCopy.php is to over-write files that exist. However, a small bug was introduced in previous version(s) where data is appended to existing files. This version of WebCopy.php fixes that bug.

Attached File: 4 - WebCopy.txt (712 B)

Chieh Cheng
Fri, 23 May 2008 08:14:19 +0000

The usage message is improved in this version of WebCopy.php to explain difference in PHP 4 versus PHP 5.

Basically in PHP 4, the download file is saved in the directory where WebCopy.php resides. On the other hand, in PHP 5, the download file is saved in the current directory, where WebCopy.php is executed.

Attached File: 5 - WebCopy.txt (1 KB)

Chieh Cheng
Wed, 07 Nov 2012 02:40:01 +0300

Add Comment | Related Links | TrackBack
Related Content

Did your message disappear? Read the Forums FAQ.

TrackBack

TrackBack only accepted from WebSite-X Suite web sites. Do not submit TrackBacks from other sites.

Send Ping | TrackBack URL | Spam Control

Title: WebCopy (Freeware)
Weblog: Cynosure.X International
Excerpt: WebCopy is a simple command-line Java program that will download any web page specified in its first argument. It will store the downloaded web page into a file specified in its second argument. The web page is specified as an URL. Because WebCopy is written as a command-line utility, it can be used . . .
Tracked: Thu, 08 Nov 2007 18:49:42 +0000

Add Comment

Spam Control | * indicates required field
Your Name: *
E-mail:
Remember Me!
Comment: *
File attachment is optional. Please do not attach a file to your submission unless it is relevent.
Attach File:
(20 MB Max)
Spam Protection: * Answer of 4 + 7?
Click button only once, please!

Messages, files, and images copyright by respective owners.

Products | Services
Forums | Latest | RSS
Library | Search | Wiki
Help | Licenses

Login | Register

117 Users Online

Hacking Digital Cameras
Fun for Photographers


Get Our

Memecoins!



Amazon Associate

Copyright © 1996 - 2024. All Rights Reserved.