CodeIgniter Forums
Upload library PDF allowed_types error workaround - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forum-23.html)
+--- Thread: Upload library PDF allowed_types error workaround (/thread-18201.html)



Upload library PDF allowed_types error workaround - El Forum - 04-28-2009

[eluser]Jay Turley[/eluser]
(Running Apache on Windows, CI 1.7.1)

I ran into the "can't upload PDFs" problem which seems to be quite popular, and after looking at the bug tracker report for the PDF bug I determined that the POST data was sending:

Content-Type: application/download

So I opened up config/mimes.php and changed the line

Code:
'pdf' => array('application/pdf', 'application/x-download'),

to
Code:
'pdf' => array('application/pdf', 'application/x-download', 'application/download'),

That solved the problem. Just want to post it here for reference and in case anyone else is searching the forums.

Oh, and it was easy to see the post data using HTTPFox