Would copy( $file, "somewhare/$file" ) be more platform independent?
--
[EMAIL PROTECTED] (ben@work untill end March)
[EMAIL PROTECTED] (ben@home)
> -----Original Message-----
> From: Chris Lee [SMTP:[EMAIL PROTECTED]]
> Sent: Monday, March 19, 2001 2:38 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] FileUpload problematic
>
> everything is working as it should. php handels its own garbage
> collection, when the script is over the file is deleted. you will have to
> copy or move the file somewhere. or just do something with it and allow
> php todo its ob and delete it when your done the script.
>
> ecec("cp $file /somewhere/$file_name");
>
>
> --
>
> Chris Lee
> [EMAIL PROTECTED]
>
>
>
> ""Thalis A. Kalfigopoulos"" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Helloppl,
> a problem with a file_upload form :-( Here is what I've done so far:
>
> File test.php which has the form is this:
> <HTML>
> <BODY>
> <?php include("handle_upload.php"); ?>
> <FORM ENCTYPE="multipart/form-data" ACTION="<?php print $PHP_SELF ?>"
> METHOD="POST">
> <INPUT TYPE="hidden" NAME="MAX_FILE_SIZE"
> VALUE="64000">
> <INPUT TYPE="submit" VALUE="go!">
> <INPUT TYPE="file" NAME="up_file">
> </FORM>
> </BODY>
> </HTML>
>
> Here is the included php file (handle_upload.php):
> <?php
> if(isset($up_file)){
> print "<P>You have succesfully sent the following file:<BR>\n";
> print "path: $up_file<BR>\n";
> print "filename: $up_file_name<BR>\n";
> print "filesize: $up_file_size<BR>\n";
> print "filetype: $up_file_type<BR>\n";
> }
> ?>
>
> When one submits a file (file exists and is within given MAX_FILE_SIZE
> boundaries), the handle_upload.php condition is true, so I get the
> following output in my browser:
>
> You have succesfully sent the following file:
> path: /tmp/phpvtMKjj
> filename: test2.jpg
> filesize: 27365
> filetype: image/jpeg
> <and again the form to upload another file>
>
> Then I go and check under /tmp and I do not find anything :-(
>
> I have in my php.ini:
> ;;;;;;;;;;;;;;;;
> ; File Uploads ;
> ;;;;;;;;;;;;;;;;
> file_uploads = On
> upload_tmp_dir = /tmp
> upload_max_filesize = 2M
>
> I am using Apache 1.3.14 with DSO and php is a .so and Php is version
> 4.0.4
>
> It is not a permissions problem cause I checked the Apache logs, and all
> dirs that need to be accessed are actually writable by the httpd user. I
> have read through "Handling file uploads"
> (http://www.php.net/manual/it/features.file-upload.php) and I don't see
> what is wrong :-(
>
>
> thanks ins advance,
> thalis
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]