Re: Upload wont work

From: Date: Fri, 24 May 2002 17:04:28 +0000
Subject: Re: Upload wont work
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-99105@lists.php.net to get a copy of this message
lol... the problem was in this line: move_uploaded_file($_FILES['userfile']['tmp_name'],"c:\\inetpub\\wwwroot\\up load\\".$_FILES['userfile']['name']); I used single backslash.. and thats no good i think ;) "Ragnar" <ragnar@chello.no> wrote in message news:20020523094301.39525.qmail@pb1.pair.com... > Hi and thanx for previous help!!! > > Still a newbie ;) > > I have tried to make the example from php manual working and have the > following code: > > upload.html: > > <form enctype="multipart/form-data" action="demo_up.php" > method="post"> > <input type="hidden" name="MAX_FILE_SIZE" value="512000"> > Send this file: <input name="userfile" type="file"> > <input type="submit" value="Send File"> > </form> > > demo_up.php: > > <?php > > function upload () > { > if ( is_uploaded_file ($_FILES['userfile']['name'] ) ) > { > copy($_FILES['userfile']['name'], "/demos/"); > } > > else > { > echo "File not uploaded: " . $_FILES['userfile']['name']; > } > } > > ?> > > <?php > upload(); > ?> > > This always ends up displaying "File not uploadet" + Filename. The file > doesnt seem to upload at all. Im using IIS 5.1 and latest version of php. > > Any ideas? > > Thanx! > >

« previous php.general (#99105) next »