Re: File upload on linux

From: Date: Fri, 19 Jan 2001 08:15:53 +0000
Subject: Re: File upload on linux
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-35591@lists.php.net to get a copy of this message
Hello MacBane, (M == "MacBane") morgan@amnesia.com.au writes: M> I have some file upload code but it is not woking on debian linux, M> could some one give me a hand <snip> M> $the_path is set some where else What is the value of $the_path? M> $path = "/var/www/cms/gentext/$section/$doctype/"; This isn't even used in the code below. It's trying to copy $the_file to $the_path. Ie. from one location, maybe /tmp if you're on Unix, to another location. Judging by '\' you might not be on a Unix machine. M> if (!@copy($the_file, $the_path."\".$the_file_name)) $the_path needs to be a valid directory -- it needs to exist, unless you use mkdir() somewhere before it. It also must be writable by the user the webserver is running as. M> { M> // print("<b>Something barfed, check u r path M> $the_path$the_file_name"); M> } M> } Find out what $the_path is and make sure it exists. -Brian -- Is it possible to feel gruntled?

« previous php.general (#35591) next »