[eluser]Patche[/eluser]
Hi,
Yep I'm aware of that. In fact, I realised that $_FILES['userfile']['type'] is set by the browser so it's not to be trusted.
However, I'm still unsure as to why the file has the application/octet-stream when it's a PDF file (I can open it in Adobe). I resaved the file as PDF and that did come up as application/pdf. Not sure how to get around this error.