Re: Re: Parse error ???

From: Date: Thu, 04 Mar 2004 18:16:17 +0000
Subject: Re: Re: Parse error ???
Groups: php.general 
Request: Send a blank email to php-general+get-179484@lists.php.net to get a copy of this message
It works now. I run the script as user mike and mike:mike is owner of the directory, when I upload something to directory the owner of the file is apache:apache. Why the owner of the file is not mike ? thanks
From: Neil Freeman <neil.freeman@asa.co.uk> To: Mike Mapsnac <mikerh9@hotmail.com> CC: michael@michaelnolan.co.uk, php-general@lists.php.net Subject: Re: [PHP] Re: Parse error ??? Date: Thu, 04 Mar 2004 13:58:26 +0000 If I remember correctly the second parameter of move_uploaded_file() needs to be the full filename, ie path plus required filename. so... if(!move_uploaded_file($_FILES['myfile']['tmp_name'], ("/var/www/html/upload/" . $_FILES['myfile']['name']))) Neil Mike Mapsnac wrote:
*********************************************** This Email Has Been Virus Swept *********************************************** brackets solve the probleb. But why I have the warning messages? The permission on the directory is correct. Any ideas what can cause such messages? Warning: move_uploaded_file(/var/www/html/upload/): failed to open stream: Is a directory in /var/www/html/uploadproc.php on line 11 Warning: move_uploaded_file(): Unable to move '/tmp/phpiMrdlQ' to '/var/www/html/upload/' in /var/www/html/uploadproc.php on line 11 Error Moving the uploaded file failed.
From: Michael Nolan <michael@michaelnolan.co.uk> To: php-general@lists.php.net Subject: [PHP] Re: Parse error ??? Date: Thu, 04 Mar 2004 13:40:46 +0000 Mike Mapsnac wrote:
The script should upload files (images). Error message is give below, any ideas why I get this errror message? Parse error: parse error in /var/www/html/uploadproc.php on line 3
die() needs brackets around its arguments, eg: die("Error! The expected file wasn't a part of the submitted form"); Mike -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
_________________________________________________________________ One-click access to Hotmail from any Web page – download MSN Toolbar now! http://clk.atdmt.com/AVE/go/onm00200413ave/direct/01/
-- ---------------------- www.curvedvision.com ---------------------- This communication is confidential to the intended recipient(s). If you are not that person you are not permitted to make use of the information and you are requested to notify the sender immediately of its receipt then destroy the copy in your possession. Any views or opinions expressed are those of the originator and may not represent those of Advanced System Architectures Ltd. *** This Email Has Been Virus Checked ***
_________________________________________________________________ Frustrated with dial-up? Lightning-fast Internet access for as low as $29.95/month. http://click.atdmt.com/AVE/go/onm00200360ave/direct/01/

« previous php.general (#179484) next »