Jump to content
Larry Ullman's Book Forums

Script 13.3 - Upload An Rtf File


Recommended Posts

I've been having some trouble with this particular script as it will not accept that the file I am trying to upload is an RTF file. I have used both my own version of the script and the version from the official answers that I downloaded from this site.

 

I am running PHP version 5.5.5 and the script is going to the invalid file type section of the IF statement. The file I am trying to upload has the .rtf extension as I understand is required, has anyone else had this problem?

Link to comment
Share on other sites

  • 3 weeks later...

Hi, apologies for the slow reply. I have printed the file type that is being uploaded with the error message and it is coming back as:

 

text/plain

 

The file is showing up as Rich Text Document in Windows Explorer with the .rtf extension. Is the problem here with the file itself or my IF statement which is looking for a text/rtf file?

Link to comment
Share on other sites

 Share

×
×
  • Create New...