Re: Upload file from my local C:
| From: | Keyur Kalaria | Date: | Tue, 10 Apr 2001 11:10:50 +0000 |
| Subject: | Re: Upload file from my local C: | ||
| References: | 1 2 3 4 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-48001@lists.php.net to get a copy of this message | ||
Hi Reiniger,
try this : copy(addslashes($file),"1.dat")
hope it is clear.
keyur
----- Original Message -----
From: "Christian Reiniger" <creinig@mayn.de>
To: "HK Woo" <hkwoo@netvigator.com>
Cc: <php-general@lists.php.net>
Sent: Tuesday, April 10, 2001 4:15 PM
Subject: Re: [PHP] Upload file from my local C:
On Monday 09 April 2001 18:35, you wrote:
> Christian
>
> Below is my script.
>
> <?
> if (!copy($file,"1.dat")) {
> echo "error"; }
> else {
> echo "successful";
> }
> ?>
>
> NOTE: where $file is passed by other html using form.
how? using a <input type='file'> ?
Then re-read the file uploading chapter in the manual
> > I use a command "copy" to upload a file from my local win machine to
> > webserver. However, it is not successful. It prompts that "Warning:
> > Unable to open 'D:\\PHP\\upload1.php' for reading:". I would like to
> > know what is the problem
--
Christian Reiniger
LGDC Webmaster (http://sunsite.dk/lgdc/)
AAAAA - American Association Against Acronym Abuse
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net
For additional commands, e-mail: php-general-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net