I have literally spent DAYS experimenting, searching, researching
RTFM'g;
and I STILL can NOT get copy() to work.
If I wrote this message the way I've been talking - there'd be an "F"
word sprinkled between almost every word. I'll spare you that - you can
insert them yourself... :)
Apparently I must be the ONLY person that wants to upload a KNOWN file
from a KNOWN path WITHOUT using a form.
I can easily get the copy() function to work using the examples in PHP
manual.
(ie: using <input type=file> in a <form>, calling into my php script).
I have [several] files that I want to repeatedly upload to a web site
(thus keeping these files current).
I SHOULD be able to do this in 1 simple script - shouldn't I?????
I've tried EVERY permutation I can think of, and many I couldn't; and
NOTHING works.
Could someone please enlighten me - WHY THE ---- DOESN'T this work:
??????
<?
$cpfrom="d:\\te mp\\blank_ms.tx t";
$cpto="./upload/junk.txt";
if (!copy($cpfrom, $cpto)) print "this blanking is STILL not wrkg<BR>";
if (!copy("$cpfrom ","$cpto")) print "this blanking is STILL not
wrkg<BR>";
if (!copy(stripsla shes($cpfrom)," $cpto"))
print "this blanking is STILL not wrkg<BR>";
if (!copy(stripsla shes($cpfrom),$ cpto))
print "this blanking is STILL not wrkg<BR>";
// there's probably another 10 variations
$cpfrom="d:\tem p\blank_ms.txt" ;
// REPEAT ABOVE tests
$cpfrom="d:/temp/blank_ms.txt";
// REPEAT ABOVE tests
$cpfrom="d%3A%5 Ctemp%5Cblank_m s.txt";
// REPEAT ABOVE tests
$cpfrom="file:///d/temp/blank_ms.txt";
// REPEAT ABOVE tests
?>
ANY help VERY much appreciated!!!
10k TIA
RTFM'g;
and I STILL can NOT get copy() to work.
If I wrote this message the way I've been talking - there'd be an "F"
word sprinkled between almost every word. I'll spare you that - you can
insert them yourself... :)
Apparently I must be the ONLY person that wants to upload a KNOWN file
from a KNOWN path WITHOUT using a form.
I can easily get the copy() function to work using the examples in PHP
manual.
(ie: using <input type=file> in a <form>, calling into my php script).
I have [several] files that I want to repeatedly upload to a web site
(thus keeping these files current).
I SHOULD be able to do this in 1 simple script - shouldn't I?????
I've tried EVERY permutation I can think of, and many I couldn't; and
NOTHING works.
Could someone please enlighten me - WHY THE ---- DOESN'T this work:
??????
<?
$cpfrom="d:\\te mp\\blank_ms.tx t";
$cpto="./upload/junk.txt";
if (!copy($cpfrom, $cpto)) print "this blanking is STILL not wrkg<BR>";
if (!copy("$cpfrom ","$cpto")) print "this blanking is STILL not
wrkg<BR>";
if (!copy(stripsla shes($cpfrom)," $cpto"))
print "this blanking is STILL not wrkg<BR>";
if (!copy(stripsla shes($cpfrom),$ cpto))
print "this blanking is STILL not wrkg<BR>";
// there's probably another 10 variations
$cpfrom="d:\tem p\blank_ms.txt" ;
// REPEAT ABOVE tests
$cpfrom="d:/temp/blank_ms.txt";
// REPEAT ABOVE tests
$cpfrom="d%3A%5 Ctemp%5Cblank_m s.txt";
// REPEAT ABOVE tests
$cpfrom="file:///d/temp/blank_ms.txt";
// REPEAT ABOVE tests
?>
ANY help VERY much appreciated!!!
10k TIA
Comment