Closed Bug 303933 Opened 19 years ago Closed 19 years ago

file handling type error on php upload

Categories

(Firefox :: General, defect)

x86
Windows XP
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: slimpchimp, Unassigned)

Details

User-Agent:       Mozilla/5.0 (compatible; Konqueror/3.4; Linux) KHTML/3.4.0 (like Gecko)
Build Identifier: Mozilla/1.0.6

I have a php uploader that only allows public to upload "text/plain" files.    
The code is:    
   
if($fupload_type != "text/plain"){   
   echo "text files only!"  
   exit();  
} else { 
   echo "upload successful!" 
} 
  
from firefox 1.0.6 on windoz xp "text files only!" is always displayed, even  
though an "echo $fupload_type" produces "text/plain".  
  
This works fine in firefox on Linux.  
  
And also works fine on internet explorer.  
  
I had to use alternative code:  
  
if(substr($fupload_name, -3, 3) != "txt")...  
  
to get windoz firefox to work appropriately.  

Reproducible: Always

Steps to Reproduce:
1.  build an uploader using code listed above  
2.  upload a text file 
3.  see that it doesn't work 
  
Actual Results:  
"text files only!" 

Expected Results:  
"upload successful!"
Using the newer $_FILES array works fine.
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
If it's not a Firefox bug, it's INVALID, not FIXED :)
Status: UNCONFIRMED → RESOLVED
Closed: 19 years ago19 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.