in reply to file handing
#!/usr/bin/perl use strict; use warnings; use autodie; my $OLDFILE = '02190.JPG'; my $NEWFILE = 'img/09911.JPG'; open my $fh, '<', $OLDFILE; binmode $fh; my $data = join '', <$fh>; close $fh; open $fh, '>', $NEWFILE; binmode $fh; print $fh $data; close $fh; print "Copied $OLDFILE to $NEWFILE\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: file handing
by bigup401 (Pilgrim) on Sep 23, 2018 at 14:07 UTC | |
by karlgoethebier (Abbot) on Sep 23, 2018 at 15:05 UTC | |
by Anonymous Monk on Sep 23, 2018 at 17:55 UTC | |
by bigup401 (Pilgrim) on Sep 23, 2018 at 20:15 UTC | |
by poj (Abbot) on Sep 23, 2018 at 20:32 UTC |