RE: [PHP] odd, sporatic upload problem ...

From: Date: Fri, 05 Mar 2004 21:56:30 +0000
Subject: RE: [PHP] odd, sporatic upload problem ...
Groups: php.general 
Request: Send a blank email to php-general+get-179609@lists.php.net to get a copy of this message
How long is it before the "Page Not Found" error occurs? Is the browser possibly timing out? --Sam Kenn Murrah wrote: > Greetings. > > I have an odd (to me) problem ... from most computers, the upload > code (shown, in part, below) works just fine .... but from at least > one > computer, if the user uploads a small file (under 1meg), it works > properly . but if he uploads a larger file he gets either a "page not > found" (Internet Explorer) or "no data" (Netscape) error .... other > users can upload files of any size, with no problem .... > > Does anyone have any ideas? > > The code (though I'm not at all sure it's relevent) is below: > > $customer_trimmed = eregi_replace("[^[:alnum:]\.]","",$customer) ; > $customer_shortened = substr($customer_trimmed,0,18); > $customer_trimmed = $customer_shortened; $folder_name = > $customer_trimmed . date("mdyHis"); > > $old_umask = umask(); > mkdir('/home/upco/uploads/' . $folder_name, 0777); > //umask($old_umask); > > $dest_dir = '/home/upco/uploads/' . $folder_name; > > error_reporting(0); > > $summary_info = "You have successfully uploaded the following > file(s):<br>" ; > for ($i=0; $i<count($_FILES['userFile']['name']); $i++) > { > $new_name = $_FILES['userFile']['name'][$i]; > $parsed_name = eregi_replace("[^[:alnum:]\.]","",$new_name) ; $dest = > $dest_dir . '/' . $parsed_name; if (!file_exists ($dest)) { > copy($_FILES['userFile']['tmp_name'][$i], $dest) ; $changepermissions > = chmod($dest, 0777);

« previous php.general (#179609) next »